diff options
author | Stefan Giehl <stefan@piwik.org> | 2018-10-01 21:03:44 +0300 |
---|---|---|
committer | diosmosis <diosmosis@users.noreply.github.com> | 2018-10-01 21:03:44 +0300 |
commit | 9af471116b03fae1f82e5c0d2b7e3666d570d926 (patch) | |
tree | 93a9d26ad450e397e35636a590a084456e48377e /plugins/Morpheus | |
parent | 723a12a32c478e3338031ab9336d4230df87bbc8 (diff) |
Ensure segment param is used from url if no hash available (#13512)
Diffstat (limited to 'plugins/Morpheus')
-rw-r--r-- | plugins/Morpheus/javascripts/ajaxHelper.js | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/plugins/Morpheus/javascripts/ajaxHelper.js b/plugins/Morpheus/javascripts/ajaxHelper.js index 5f8f171321..743ac28dee 100644 --- a/plugins/Morpheus/javascripts/ajaxHelper.js +++ b/plugins/Morpheus/javascripts/ajaxHelper.js @@ -529,10 +529,16 @@ function ajaxHelper() { */ this._mixinDefaultGetParams = function (params) { + if (window.location.hash) { + var segment = broadcast.getValueFromHash('segment', window.location.href.split('#')[1]); + } else { + var segment = broadcast.getValueFromUrl('segment'); + } + var defaultParams = { idSite: piwik.idSite || broadcast.getValueFromUrl('idSite'), period: piwik.period || broadcast.getValueFromUrl('period'), - segment: broadcast.getValueFromHash('segment', window.location.href.split('#')[1]) + segment: segment }; // never append token_auth to url |