[FIX] website: use underscore's startsWith method for browser support

Since ES6's startsWith method is not supported by all/old browser, replace it
with underscore's one
This commit is contained in:
Romain Derie
2017-11-15 12:56:02 +01:00
parent 1db3829540
commit 86e79881e8
+1 -1
View File
@@ -69,7 +69,7 @@ var PagePropertiesDialog = widget.Dialog.extend({
context: context
},
}).then(function (page) {
page[0].url = page[0].url.startsWith('/') ? page[0].url.substring(1) : page[0].url;
page[0].url = _.str.startsWith(page[0].url, '/') ? page[0].url.substring(1) : page[0].url;
self.page = page[0];
}));