Removed unneeded code

Added more comments