Fixed slider, added checks for valid files