mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 13:12:50 +01:00
Cleanup for Custom Translations
This commit is contained in:
parent
ab5dc13662
commit
c29c6ba480
@ -18,8 +18,21 @@ class NinjaTranslationServiceProvider extends TranslationServiceProvider
|
|||||||
{
|
{
|
||||||
public function boot()
|
public function boot()
|
||||||
{
|
{
|
||||||
//parent::boot();
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* To reset the translator instance we call
|
||||||
|
*
|
||||||
|
* App::forgetInstance('translator');
|
||||||
|
*
|
||||||
|
* Why? As the translator is a singleton it persists for its
|
||||||
|
* lifecycle
|
||||||
|
*
|
||||||
|
* We _must_ reset the singleton when shifting between
|
||||||
|
* clients/companies otherwise translations will
|
||||||
|
* persist.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
$this->app->singleton('translator', function($app)
|
$this->app->singleton('translator', function($app)
|
||||||
{
|
{
|
||||||
$loader = $app['translation.loader'];
|
$loader = $app['translation.loader'];
|
||||||
|
Loading…
Reference in New Issue
Block a user