summaryrefslogtreecommitdiff
path: root/modules/gallery/libraries
diff options
context:
space:
mode:
authorAndy Staudacher <andy.st@gmail.com>2010-02-16 23:54:39 -0800
committerAndy Staudacher <andy.st@gmail.com>2010-02-16 23:54:39 -0800
commit4ca55a90ee2f8e1d8595b0ec53a601d6c65475f6 (patch)
tree3abf64c22ec2f7d3c5976e29a94d26279508e176 /modules/gallery/libraries
parent3b1b2bfea9592269717fdd462fb1e5137bd4f8dd (diff)
Fix for ticket #1017: Handle the common case of t(html::clean($var)) by casting SafeString instances to string in translate().
Diffstat (limited to 'modules/gallery/libraries')
-rw-r--r--modules/gallery/libraries/Gallery_I18n.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/gallery/libraries/Gallery_I18n.php b/modules/gallery/libraries/Gallery_I18n.php
index cfed046a..160543c9 100644
--- a/modules/gallery/libraries/Gallery_I18n.php
+++ b/modules/gallery/libraries/Gallery_I18n.php
@@ -117,6 +117,9 @@ class Gallery_I18n_Core {
$count = isset($options['count']) ? $options['count'] : null;
$values = $options;
unset($values['locale']);
+ if ($message instanceof SafeString) {
+ $message = (string) $message;
+ }
$this->log($message, $options);
$entry = $this->lookup($locale, $message);