Got rid of unecessary code