implemented comments from code review