added changes after code review