storage.js: Use substring instead of startsWith on strings
IE11 doesn't support startsWith..
This commit is contained in:
parent
f11de266f4
commit
2280551484
|
@ -37,7 +37,7 @@
|
|||
*/
|
||||
window.addEventListener('storage', function(event) {
|
||||
var url = icinga.utils.parseUrl(event.url);
|
||||
if (! url.path.startsWith(icinga.config.baseUrl)) {
|
||||
if (! url.path.substring(0, icinga.config.baseUrl.length) === icinga.config.baseUrl) {
|
||||
// A localStorage is shared between all paths on the same origin.
|
||||
// So we need to make sure it's us who made a change.
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue