FakerImageGeneratorServiceProvider::boot()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 13

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 13
c 0
b 0
f 0
rs 9.8333
cc 2
nc 2
nop 0
1
<?php
2
3
namespace Swatty007\FakerImageGenerator;
4
5
use Illuminate\Support\ServiceProvider;
6
7
class FakerImageGeneratorServiceProvider extends ServiceProvider
8
{
9
    /**
10
     * Bootstrap the application services.
11
     */
12
    public function boot()
13
    {
14
        if ($this->app->runningInConsole()) {
15
            $this->publishes([
16
                __DIR__.'/../config/config.php' => config_path('faker-image-generator.php'),
17
            ], 'config');
18
19
            // Publishing assets.
20
            $this->publishes([
21
                __DIR__.'/../resources/assets' => public_path('vendor/faker-image-generator'),
22
            ], 'assets');
23
        }
24
    }
25
26
    /**
27
     * Register the application services.
28
     */
29
    public function register()
30
    {
31
        // Automatically apply the package configuration
32
        $this->mergeConfigFrom(__DIR__.'/../config/config.php', 'faker-image-generator');
33
    }
34
}
35