fixes adding new routes to user/xxx/route

This commit is contained in:
psychobunny
2015-01-09 14:33:42 -05:00
parent a8de1c1465
commit a7d73d4106
2 changed files with 3 additions and 2 deletions

View File

@@ -195,7 +195,8 @@ $(document).ready(function() {
ajaxify.getCustomTemplateMapping = function(tpl) {
if (templatesModule.config && templatesModule.config.custom_mapping && tpl !== undefined) {
for (var pattern in templatesModule.config.custom_mapping) {
if (tpl.match(pattern)) {
var match = tpl.match(pattern);
if (match && match[0] === tpl) {
return (templatesModule.config.custom_mapping[pattern]);
}
}

View File

@@ -13,7 +13,7 @@
"^user/.*/favourites": "account/favourites",
"^user/.*/posts": "account/posts",
"^user/.*/topics": "account/topics",
"^user/.*": "account/profile",
"^user/[.^\/]*": "account/profile",
"^reset/.*": "reset_code",
"^tags/.*": "tag",
"^groups/?$": "groups/list",