diff --git a/resources/views/accounts/nav.blade.php b/resources/views/accounts/nav.blade.php
index 338a7b462a05..e0ab9168bcb9 100644
--- a/resources/views/accounts/nav.blade.php
+++ b/resources/views/accounts/nav.blade.php
@@ -1,11 +1,27 @@
@if (!Utils::isPro() && isset($advanced) && $advanced)
-
diff --git a/resources/views/header.blade.php b/resources/views/header.blade.php
index b1d3504f54c7..d8066601e022 100644
--- a/resources/views/header.blade.php
+++ b/resources/views/header.blade.php
@@ -337,6 +337,9 @@
if (history.pushState) {
history.pushState(null, null, target);
}
+ if (isStorageSupported() && /\/settings\//.test(location.href)) {
+ localStorage.setItem('last:settings_page', location.href);
+ }
});
});
diff --git a/resources/views/partials/keyboard_shortcuts.blade.php b/resources/views/partials/keyboard_shortcuts.blade.php
index f708d5fe0b7d..9f635d606171 100644
--- a/resources/views/partials/keyboard_shortcuts.blade.php
+++ b/resources/views/partials/keyboard_shortcuts.blade.php
@@ -103,7 +103,11 @@
});
Mousetrap.bind('g s', function(e) {
- location.href = "{{ url('/settings/company_details') }}";
+ var url = '{{ url('/settings/company_details') }}';
+ if (isStorageSupported()) {
+ url = localStorage.getItem('last:settings_page') || url;
+ }
+ location.href = url;
});
Mousetrap.bind('h', function(e) {