Completed
Push — master ( 8b7e0e...a6c71b )
by Marcel
9s
created

LumenQueryDetectorServiceProvider   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 1
lcom 1
cbo 2
dl 0
loc 16
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A register() 0 12 1
1
<?php
2
namespace BeyondCode\QueryDetector;
3
4
use Illuminate\Support\ServiceProvider;
5
6
class LumenQueryDetectorServiceProvider extends ServiceProvider
7
{
8
9
    public function register()
10
    {
11
        $this->app->configure('querydetector');
0 ignored issues
show
Bug introduced by
The method configure() does not exist on Illuminate\Contracts\Foundation\Application. Did you maybe mean registerConfiguredProviders()?

This check marks calls to methods that do not seem to exist on an object.

This is most likely the result of a method being renamed without all references to it being renamed likewise.

Loading history...
12
        $this->mergeConfigFrom(__DIR__ . '/../config/config.php', 'querydetector');
13
14
        $this->app->middleware([
0 ignored issues
show
Bug introduced by
The method middleware() does not seem to exist on object<Illuminate\Contra...Foundation\Application>.

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...
15
            QueryDetectorMiddleware::class
16
        ]);
17
18
        $this->app->singleton(QueryDetector::class);
19
        $this->app->alias(QueryDetector::class, 'querydetector');
20
    }
21
}
22