diff options
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/gallery/libraries/Menu.php | 5 | 
1 files changed, 5 insertions, 0 deletions
| diff --git a/modules/gallery/libraries/Menu.php b/modules/gallery/libraries/Menu.php index fba21e09..20405317 100644 --- a/modules/gallery/libraries/Menu.php +++ b/modules/gallery/libraries/Menu.php @@ -43,6 +43,11 @@ class Menu_Element {     * @chainable     */    public function label($label) { +    // Guard against developers who forget to internationalize label strings +    if (!($label instanceof SafeString)) { +      $label = new SafeString($label); +    } +      $this->label = $label;      return $this;    } | 
