Skip to content
This repository has been archived by the owner on Aug 18, 2018. It is now read-only.

Commit

Permalink
Fixed bug on domain change call
Browse files Browse the repository at this point in the history
No re-creates the domain catalog on change.
  • Loading branch information
shaggyz committed Nov 14, 2016
1 parent 0a226c6 commit 59d657f
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/Xinax/LaravelGettext/Translators/Symfony.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,21 @@ public function setLocale($locale)
return $this;
}

/**
* Set domain overload.
* Needed to re-build the catalogue when domain changes.
*
* @param $locale
* @return $this
*/
public function setDomain($domain)
{
parent::setDomain($domain);

$this->symfonyTranslator = $this->createTranslator();
return $this;
}

/**
* Creates a new translator instance
*
Expand Down

0 comments on commit 59d657f

Please sign in to comment.