We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ae8462e commit 2638787Copy full SHA for 2638787
1 file changed
emmett_core/routing/router.py
@@ -108,9 +108,9 @@ def _split_lang(router, path):
108
clean_path = path.lstrip("/")
109
next_sep = clean_path[2:3]
110
if not next_sep or next_sep == "/":
111
- lang, new_path = clean_path[:2], clean_path[2:]
+ lang, new_path = clean_path[:2], (clean_path[2:] or "/")
112
if lang != default and lang in router.app._languages_set:
113
- return "/" + new_path, lang
+ return new_path, lang
114
return path, default
115
116
@classmethod
0 commit comments