SmsGlobalServiceProvider   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Importance

Changes 3
Bugs 0 Features 0
Metric Value
wmc 2
eloc 6
c 3
b 0
f 0
dl 0
loc 26
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A register() 0 5 1
A boot() 0 6 1
1
<?php
2
3
namespace JoshuaChinemezu\SmsGlobal;
4
5
use Illuminate\Support\ServiceProvider;
6
7
class SmsGlobalServiceProvider extends ServiceProvider
8
{
9
    /**
10
     * Register services.
11
     *
12
     * @return void
13
     */
14
    public function register()
15
    {
16
        $this->app->bind('smsglobal-laravel', function () {
0 ignored issues
show
Bug introduced by
The method bind() does not exist on Tests\Laravel\App. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

16
        $this->app->/** @scrutinizer ignore-call */ 
17
                    bind('smsglobal-laravel', function () {

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
17
18
            return new RestApi\RestApiClient;
19
        });
20
    }
21
22
    /**
23
     * Bootstrap services.
24
     *
25
     * @return void
26
     */
27
    public function boot()
28
    {
29
        $config = realpath(__DIR__ . '/../config/smsglobal.php');
30
31
        $this->publishes([
0 ignored issues
show
Bug introduced by
The method publishes() does not exist on JoshuaChinemezu\SmsGlobal\SmsGlobalServiceProvider. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

31
        $this->/** @scrutinizer ignore-call */ 
32
               publishes([

This check looks for calls to methods that do not seem to exist on a given type. It looks for the method on the type itself as well as in inherited classes or implemented interfaces.

This is most likely a typographical error or the method has been renamed.

Loading history...
32
            $config => config_path('smsglobal.php')
33
        ]);
34
    }
35
}
36