Permalink
Browse files

Fix `t` fallback for missing keys

  • Loading branch information...
1 parent ba586a6 commit 7bf9dc173565d2ad5d676b7cff6df73238d7c1b2 @ptaoussanis committed Mar 28, 2013
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/taoensso/tower.clj
View
@@ -473,7 +473,8 @@
;; Try fall back to :missing key in named or default locale
(when-let [pattern (some get-in-dict (for [l @lchoices*]
[l :missing]))]
- (format-msg pattern @missing-args)))))))))))
+ ;; Use 's to escape {}'s for MessageFormat
+ (format-msg pattern (str "'" @missing-args "'"))))))))))))
(comment (with-locale :en-ZA (t :example/foo))
(with-locale :en-ZA (with-scope :example (t :foo)))

0 comments on commit 7bf9dc1

Please sign in to comment.