Example #1
0
 /**
  * Allows calling registered helpers depending on locale.
  *
  * @param  mixed
  * @param  callable
  */
 public function callWithLocalization($locale, $callback)
 {
     $originalLocale = $this->registry->getLocale();
     $this->registry->setLocale($locale);
     call_user_func($callback, $this);
     $this->registry->setLocale($originalLocale);
 }