diff --git a/frappe/public/js/frappe/router.js b/frappe/public/js/frappe/router.js index 8c19c57876..b75e650ae8 100644 --- a/frappe/public/js/frappe/router.js +++ b/frappe/public/js/frappe/router.js @@ -225,7 +225,7 @@ frappe.router = { // Hence if this check is true, instead of changing location hash, // we just do a back to go to the doc previous to the "new-doctype-1" var re_route_val = this.get_sub_path(frappe.re_route[sub_path]); - if (decodeURIComponent(re_route_val) === decodeURIComponent(sub_path)) { + if (decodeURIComponent(re_route_val) !== decodeURIComponent(sub_path)) { window.history.back(); return true; } else {