Completed
Push — master ( b8f451...161d28 )
by Dwight
9s
created

ApnServiceProvider::boot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 12
Code Lines 7

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 12
ccs 0
cts 11
cp 0
rs 9.4285
cc 1
eloc 7
nc 1
nop 0
crap 2
1
<?php
2
3
namespace NotificationChannels\Apn;
4
5
use Illuminate\Support\ServiceProvider;
6
7
class ApnServiceProvider extends ServiceProvider
8
{
9
    public function boot()
10
    {
11
        $this->app->bind(ApnCredentials::class, function ($app) {
12
            $config = $app['config'];
13
14
            return new ApnCredentials(
15
                $config->get('broadcasting.connections.apn.environment'),
16
                $config->get('broadcasting.connections.apn.certificate'),
17
                $config->get('broadcasting.connections.apn.pass_phrase')
18
            );
19
        });
20
    }
21
}
22