diff --git a/frappe/public/js/frappe/router.js b/frappe/public/js/frappe/router.js index b5fd468a4a..ee6b5b4c07 100644 --- a/frappe/public/js/frappe/router.js +++ b/frappe/public/js/frappe/router.js @@ -64,8 +64,12 @@ frappe.get_route_str = function(route) { route = $.map(route.split('/'), function(r) { try { return decodeURIComponent(r); - } catch(e if e instanceof URIError) { - return r; + } catch(e) { + if (e instanceof URIError) { + return r; + } else { + throw e; + } } }).join('/');