Resolved some major and minor code review issues