Minor refactoring according to feedbacks