removed useless code and added useless comments