]> git.openstreetmap.org Git - rails.git/blobdiff - app/assets/javascripts/leaflet.share.js
Enable some more eslint checks
[rails.git] / app / assets / javascripts / leaflet.share.js
index 92f6cd881f8264e7e9a980963257e060adbb8e11..bca8e5c6a6d7ba5d5db43b1e383bcf3f4de54860 100644 (file)
@@ -313,7 +313,7 @@ L.OSM.share = function (options) {
         "\"": """,
         "'": "'"
       };
-      return string === null ? "" : (string + "").replace(/[&<>"']/g, function(match) {
+      return string === null ? "" : String(string).replace(/[&<>"']/g, function(match) {
         return htmlEscapes[match];
       });
     }