PushoverServiceProvider   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 5

Test Coverage

Coverage 71.43%

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 5
dl 0
loc 21
ccs 5
cts 7
cp 0.7143
c 0
b 0
f 0
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A register() 0 3 1
A boot() 0 8 1
1
<?php
2
3
namespace NotificationChannels\Pushover;
4
5
use GuzzleHttp\Client as HttpClient;
6
use Illuminate\Support\ServiceProvider;
7
8
class PushoverServiceProvider extends ServiceProvider
9
{
10
    /**
11
     * Bootstrap the application services.
12
     */
13 1
    public function boot()
14
    {
15
        $this->app->when(PushoverChannel::class)
16
            ->needs(Pushover::class)
17 1
            ->give(function () {
18 1
                return new Pushover(new HttpClient(), config('services.pushover.token'));
19 1
            });
20 1
    }
21
22
    /**
23
     * Register the application services.
24
     */
25
    public function register()
26
    {
27
    }
28
}
29