CASServerServiceProvider::boot()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 22

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 6

Importance

Changes 0
Metric Value
cc 2
nc 2
nop 0
dl 0
loc 22
ccs 0
cts 19
cp 0
crap 6
rs 9.568
c 0
b 0
f 0
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: chenyihong
5
 * Date: 16/8/13
6
 * Time: 17:49
7
 */
8
9
namespace Leo108\CAS;
10
11
use Illuminate\Support\ServiceProvider;
12
13
/**
14
 * Class CASServerServiceProvider
15
 * @package Leo108\CAS
16
 */
17
class CASServerServiceProvider extends ServiceProvider
18
{
19
    /**
20
     * @inheritdoc
21
     */
22
    public function register()
23
    {
24
    }
25
26
    /**
27
     * @inheritdoc
28
     */
29
    public function boot()
30
    {
31
        require __DIR__.'/helpers.php';
32
33
        if (!$this->app->routesAreCached()) {
34
            require __DIR__.'/Http/routes.php';
35
        }
36
37
        $this->publishes(
38
            [
39
                __DIR__.'/../config/cas.php' => config_path('cas.php'),
40
            ],
41
            'config'
42
        );
43
44
        $this->publishes(
45
            [
46
                __DIR__.'/../database/migrations/' => database_path('migrations'),
47
            ],
48
            'migrations'
49
        );
50
    }
51
}
52