diff --git a/app/assets/javascripts/discourse/dialects/dialect.js b/app/assets/javascripts/discourse/dialects/dialect.js index d8fd7298dec..495d0fa6720 100644 --- a/app/assets/javascripts/discourse/dialects/dialect.js +++ b/app/assets/javascripts/discourse/dialects/dialect.js @@ -167,7 +167,7 @@ Discourse.Dialect = { var keys = Object.keys(hoisted); if (keys.length) { keys.forEach(function(k) { - result = result.replace(k, hoisted[k]); + result = result.replace(new RegExp(k,"g"), hoisted[k]); }); }