remove unnecessary directory separator