removes trailing slashes