diff --git a/app/src/download.js b/app/src/download.js index a794914..2fb8d0b 100644 --- a/app/src/download.js +++ b/app/src/download.js @@ -1,3 +1,10 @@ +if(!String.prototype.startsWith) { + String.prototype.startsWith = function(searchString, position) { + position = position || 0; + return this.indexOf(searchString, position) === position; + }; +} + import Vue from 'vue'; import Download from './Download.vue'; import Icon from 'vue-awesome/components/Icon.vue' diff --git a/app/src/upload.js b/app/src/upload.js index 4e00c67..4e28a77 100644 --- a/app/src/upload.js +++ b/app/src/upload.js @@ -1,3 +1,10 @@ +if(!String.prototype.startsWith) { + String.prototype.startsWith = function(searchString, position) { + position = position || 0; + return this.indexOf(searchString, position) === position; + }; +} + import Vue from 'vue'; import Upload from './Upload.vue'; import store from './Upload/store.js';