diff --git a/scripts/shared/utilities.js b/scripts/shared/utilities.js index 35f1a083..1bbc53d5 100644 --- a/scripts/shared/utilities.js +++ b/scripts/shared/utilities.js @@ -2316,8 +2316,10 @@ function removeHexColoursFromString(str) { // =========================================================================== function removeSlashesFromString(str) { - let matchRegex = /\//gi; - str.replace(matchRegex, ``); + if (str == "") { + let matchRegex = /\//gi; + str.replace(matchRegex, ``); + } return str; }