Completed
Push — master ( 54524b...75003d )
by Chin
01:07
created

LaravelLocalesServiceProvider::boot()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 10

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 2
nc 2
nop 0
dl 0
loc 10
rs 9.9332
c 0
b 0
f 0
1
<?php
2
3
namespace ChinLeung\LaravelLocales;
4
5
use Illuminate\Support\ServiceProvider;
6
7
class LaravelLocalesServiceProvider extends ServiceProvider
8
{
9
    /**
10
     * Bootstrap the application services.
11
     */
12
    public function boot()
13
    {
14
        require __DIR__.'/helpers.php';
15
16
        if ($this->app->runningInConsole()) {
17
            $this->publishes([
18
                __DIR__.'/../config/config.php' => config_path('laravel-locales.php'),
19
            ], 'config');
20
        }
21
    }
22
23
    /**
24
     * Register the application services.
25
     */
26
    public function register()
27
    {
28
        $this->mergeConfigFrom(__DIR__.'/../config/config.php', 'laravel-locales');
29
    }
30
}
31