Skip to content

Commit 3813dae

Browse files
committed
Merge pull request #182 from MartinFournier/v2-core-logkey
[v2] core: Log argument key for mf() to ease debugging
2 parents ce7505d + b44975a commit 3813dae

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

msgfmt:core/lib/mfPkg/messageformat.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,11 @@ mf = function(key, params, message, locale) {
133133
if (currentInvocation)
134134
locale = currentInvocation.connection.locale;
135135
else {
136-
console.log("[msgfmt] You called mf() outside of a method/publish and " +
137-
"without specifying a locale, defaulting to native (" + msgfmt.native + ")");
136+
console.log(
137+
"[msgfmt] You called mf() with the key '" + key +
138+
"' outside of a method/publish and " +
139+
"without specifying a locale, defaulting to native (" + msgfmt.native + ")"
140+
);
138141
locale = msgfmt.native;
139142
}
140143

0 commit comments

Comments
 (0)