Skip to content

Commit 7666413

Browse files
shawnhooperrmariuzzo
authored andcommitted
Change major version checks to be >= 5, which fixes Laravel 6 support, (#140)
but also keeps the plugin working through future major releases.
1 parent 9bb8e85 commit 7666413

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Mariuzzo/LaravelJsLocalization/LaravelJsLocalizationServiceProvider.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public function boot()
4848
if ($laravelMajorVersion === 4) {
4949
$config = $this->app['config']->get($configKey, []);
5050
$this->app['config']->set($configKey, array_merge(require $configPath, $config));
51-
} elseif ($laravelMajorVersion === 5) {
51+
} elseif ($laravelMajorVersion >= 5) {
5252
$this->publishes([
5353
$configPath => config_path("$configKey.php"),
5454
]);
@@ -72,7 +72,7 @@ public function register()
7272

7373
if ($laravelMajorVersion === 4) {
7474
$langs = $app['path.base'].'/app/lang';
75-
} elseif ($laravelMajorVersion === 5 || $laravelMajorVersion === 6) {
75+
} elseif ($laravelMajorVersion >= 5) {
7676
$langs = $app['path.base'].'/resources/lang';
7777
}
7878
$messages = $app['config']->get('localization-js.messages');

0 commit comments

Comments
 (0)