Removed duplicate code

fixed borken slider