removed useless lines, added comments