src/Charcoal/Admin/Template/ElfinderTemplate.php
public function addLocalization($ident, $translations)
    {
        if (!is_string($ident)) {
            throw new InvalidArgumentException(sprintf(
                'Translation key must be a string, received %s',
                (is_object($ident) ? get_class($ident) : gettype($ident))
            ));
        }

        $this->localizations[$ident] = $this->translator()->translation($translations);

        return $this;
    }
public function addLocalization($ident, $translations)
    {
        if (!is_string($ident)) {
            throw new InvalidArgumentException(sprintf(
                'Translation key must be a string, received %s',
                (is_object($ident) ? get_class($ident) : gettype($ident))
            ));
        }

        $this->localizations[$ident] = $this->translator()->translation($translations);

        return $this;
    }
public function addLocalization ( $ ident , $ translations ) { if ( ! is_string ( $ ident ) ) { throw new InvalidArgumentException ( sprintf ( 'Translation key must be a string, received %s' , ( is_object ( $ ident ) ? get_class ( $ ident ) : gettype ( $ ident ) ) ) ) ; } $ this -> localizations [ $ ident ] = $ this -> translator ( ) -> translation ( $ translations ) ; return $ this ; }
Add a custom localization message.

@param  string $ident        The message ID.
@param  mixed  $translations The message translations.
@throws InvalidArgumentException If the message ID is not a string or the translations are invalid.
@return self
Add a custom localization message .