FlashServiceProvider::boot()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
dl 0
loc 6
rs 9.4285
c 1
b 0
f 0
cc 1
eloc 3
nc 1
nop 0
1
<?php
2
3
namespace Jalle19\Laravel\UnshittyFlash;
4
5
use Illuminate\Support\ServiceProvider;
6
7
/**
8
 * Class FlashServiceProvider
9
 * @package Jalle19\Laravel\UnshittyFlash
10
 */
11
class FlashServiceProvider extends ServiceProvider
12
{
13
14
    /**
15
     * Registers bindings into the container
16
     */
17
    public function register()
18
    {
19
        $this->app->singleton(FlashService::class, function() {
20
            return new FlashService(config('flash'));
21
        });
22
    }
23
24
25
    /**
26
     *
27
     */
28
    public function boot()
29
    {
30
        $this->publishes([
31
            __DIR__ . '/../config/flash.php' => config_path('flash.php'),
32
        ]);
33
    }
34
35
}
36