From 3ee2909ed58a8b38ec8b2144f9c8113f42bd0151 Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Mon, 8 Apr 2019 19:51:48 +0000 Subject: [PATCH] --- ayanova/src/api/locale.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ayanova/src/api/locale.js b/ayanova/src/api/locale.js index 40c50066..3257d546 100644 --- a/ayanova/src/api/locale.js +++ b/ayanova/src/api/locale.js @@ -125,7 +125,11 @@ export default { var pattern = /\[(.*?)\]/g; var match; while ((match = pattern.exec(s)) != null) { - ret.replace(match, this.get(match)); + var foundMatch = match[0]; + var ltKey = match[1]; + var newValue = this.get(ltKey); + + ret = ret.replace(foundMatch, newValue); } return ret; }