Beispiel #1
0
 /**
  * Return the translated passed string
  * @param string $sentence
  * @return string|string
  */
 public function _($sentence)
 {
     if ($this->translator != null && $this->translator instanceof ITranslator) {
         return $this->translator->_($sentence);
     }
     return $sentence;
 }
Beispiel #2
0
 /**
  * Return the translated sentence
  * @param string $sentence
  * @return string
  */
 public function _($sentence)
 {
     if ($this->translator === null) {
         return $sentence;
     }
     return $this->translator->_($sentence);
 }