escapeKeyCharacters is now a common utility

This commit is contained in:
ansuz 2019-09-12 17:24:40 +02:00
parent c17a28cced
commit abaf4c7371
1 changed files with 8 additions and 0 deletions

View File

@ -130,6 +130,14 @@
return C;
};
Util.escapeKeyCharacters = function (key) {
return key && key.replace && key.replace(/\//g, '-');
};
Util.unescapeKeyCharacters = function (key) {
return key.replace(/\-/g, '/');
};
Util.deduplicateString = function (array) {
var a = array.slice();
for(var i=0; i<a.length; i++) {