Removes unncessary code.