UrlGenerator   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
dl 0
loc 14
rs 10
c 1
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A getFacadeAccessor() 0 7 2
1
<?php
2
3
namespace Trucker\Facades;
4
5
use Illuminate\Support\Facades\Facade;
6
use Trucker\TruckerServiceProvider;
7
8
/**
9
 * Facade class for interacting with the Trucker UrlGenerator class.
10
 *
11
 * @author Alessandro Manno <[email protected]>
12
 */
13
class UrlGenerator extends Facade
14
{
15
    /**
16
     * Get the registered name of the component.
17
     *
18
     * @return string
19
     */
20
    protected static function getFacadeAccessor()
21
    {
22
        if (!static::$app) {
23
            static::$app = TruckerServiceProvider::make();
0 ignored issues
show
Documentation Bug introduced by
It seems like Trucker\TruckerServiceProvider::make() of type Illuminate\Container\Container is incompatible with the declared type Illuminate\Foundation\Application of property $app.

Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.

Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..

Loading history...
24
        }
25
26
        return 'trucker.urls';
27
    }
28
}
29