/** * Translate a text * * @param string $sentence The text that will be translated * @param array $placeholders (optional) An array of placeholders * @param string $lang (optional) Translation language * * @return string Translated text */ public function t($sentence, $placeholders = array(), $lang = null) { return $this->app->t($sentence, $placeholders, $lang); }
/** * Push a validator * * @param array $item * * @return $this */ protected function push(array $item) { $item['error']['text'] = $this->app->t($item['error']['text']); return parent::push($item); }