@@ -40,10 +40,10 @@ discard block |
||
40 | 40 | public function boot() |
41 | 41 | { |
42 | 42 | $this->publishes([ |
43 | - __DIR__ . '/../config/translator.php' => config_path('translator.php'), |
|
44 | - __DIR__ . '/../config/translation.php' => config_path('translation.php'), |
|
43 | + __DIR__.'/../config/translator.php' => config_path('translator.php'), |
|
44 | + __DIR__.'/../config/translation.php' => config_path('translation.php'), |
|
45 | 45 | ]); |
46 | - $this->loadMigrationsFrom(__DIR__ . '/../database/migrations/'); |
|
46 | + $this->loadMigrationsFrom(__DIR__.'/../database/migrations/'); |
|
47 | 47 | |
48 | 48 | |
49 | 49 | $this->registerCacheRepository(); |
@@ -58,8 +58,8 @@ discard block |
||
58 | 58 | */ |
59 | 59 | public function register() |
60 | 60 | { |
61 | - $this->mergeConfigFrom(__DIR__ . '/../config/translator.php', 'translator'); |
|
62 | - $this->mergeConfigFrom(__DIR__ . '/../config/translation.php', 'translation'); |
|
61 | + $this->mergeConfigFrom(__DIR__.'/../config/translator.php', 'translator'); |
|
62 | + $this->mergeConfigFrom(__DIR__.'/../config/translation.php', 'translation'); |
|
63 | 63 | |
64 | 64 | $this->registerPresenceVerifier(); |
65 | 65 | |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | parent::register(); |
84 | 84 | |
85 | 85 | // Bind translation to the IoC. |
86 | - $this->app->bind('translation', function (Application $app) { |
|
86 | + $this->app->bind('translation', function(Application $app) { |
|
87 | 87 | return new Translation($app); |
88 | 88 | }); |
89 | 89 | |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | /** |
94 | 94 | * Provider Antigo |
95 | 95 | */ |
96 | - Blade::directive('t', function ($args) { |
|
96 | + Blade::directive('t', function($args) { |
|
97 | 97 | return "<?php echo App::make('translation')->translate{$args}; ?>"; |
98 | 98 | }); |
99 | 99 | |
@@ -129,20 +129,20 @@ discard block |
||
129 | 129 | protected function registerLoader() |
130 | 130 | { |
131 | 131 | $app = $this->app; |
132 | - $this->app->singleton('translation.loader', function ($app) { |
|
132 | + $this->app->singleton('translation.loader', function($app) { |
|
133 | 133 | $defaultLocale = $app['config']->get('app.locale'); |
134 | 134 | $loader = null; |
135 | 135 | $source = $app['config']->get('translator.source'); |
136 | 136 | |
137 | 137 | switch ($source) { |
138 | 138 | case 'mixed': |
139 | - $laravelFileLoader = new LaravelFileLoader($app['files'], $app->basePath() . '/resources/lang'); |
|
139 | + $laravelFileLoader = new LaravelFileLoader($app['files'], $app->basePath().'/resources/lang'); |
|
140 | 140 | $fileLoader = new FileLoader($defaultLocale, $laravelFileLoader); |
141 | 141 | $databaseLoader = new DatabaseLoader($defaultLocale, $app->make(TranslationRepository::class)); |
142 | 142 | $loader = new MixedLoader($defaultLocale, $fileLoader, $databaseLoader); |
143 | 143 | break; |
144 | 144 | case 'mixed_db': |
145 | - $laravelFileLoader = new LaravelFileLoader($app['files'], $app->basePath() . '/resources/lang'); |
|
145 | + $laravelFileLoader = new LaravelFileLoader($app['files'], $app->basePath().'/resources/lang'); |
|
146 | 146 | $fileLoader = new FileLoader($defaultLocale, $laravelFileLoader); |
147 | 147 | $databaseLoader = new DatabaseLoader($defaultLocale, $app->make(TranslationRepository::class)); |
148 | 148 | $loader = new MixedLoader($defaultLocale, $databaseLoader, $fileLoader); |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | $loader = new DatabaseLoader($defaultLocale, $app->make(TranslationRepository::class)); |
152 | 152 | break; |
153 | 153 | default:case 'files': |
154 | - $laravelFileLoader = new LaravelFileLoader($app['files'], $app->basePath() . '/resources/lang'); |
|
154 | + $laravelFileLoader = new LaravelFileLoader($app['files'], $app->basePath().'/resources/lang'); |
|
155 | 155 | $loader = new FileLoader($defaultLocale, $laravelFileLoader); |
156 | 156 | break; |
157 | 157 | } |
@@ -169,7 +169,7 @@ discard block |
||
169 | 169 | */ |
170 | 170 | public function registerCacheRepository() |
171 | 171 | { |
172 | - $this->app->singleton('translation.cache.repository', function ($app) { |
|
172 | + $this->app->singleton('translation.cache.repository', function($app) { |
|
173 | 173 | $cacheStore = $app['cache']->getStore(); |
174 | 174 | return CacheRepositoryFactory::make($cacheStore, $app['config']->get('translator.cache.suffix')); |
175 | 175 | }); |
@@ -186,7 +186,7 @@ discard block |
||
186 | 186 | $defaultLocale = $app['config']->get('app.locale'); |
187 | 187 | $languageRepository = $app->make(LanguageRepository::class); |
188 | 188 | $translationRepository = $app->make(TranslationRepository::class); |
189 | - $translationsPath = $app->basePath() . '/resources/lang'; |
|
189 | + $translationsPath = $app->basePath().'/resources/lang'; |
|
190 | 190 | $command = new FileLoaderCommand($languageRepository, $translationRepository, $app['files'], $translationsPath, $defaultLocale); |
191 | 191 | |
192 | 192 | $this->app['command.translator:load'] = $command; |