pub fn normalize_route(input: &str) -> String
Normalizes repeated slashes and removes trailing slashes except for the root route.