GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( bb179b...635300 )
by Shea
04:59
created

ServiceProvider   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Importance

Changes 1
Bugs 0 Features 1
Metric Value
wmc 3
c 1
b 0
f 1
lcom 1
cbo 1
dl 0
loc 21
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A addMiddleware() 0 12 3
1
<?php
2
3
namespace Caffeinated\Modules\Support;
4
5
use Illuminate\Support\ServiceProvider as IlluminateServiceProvider;
6
7
class ServiceProvider extends IlluminateServiceProvider
0 ignored issues
show
Bug introduced by
There is one abstract method register in this class; you could implement it, or declare this class as abstract.
Loading history...
8
{
9
    /**
10
     * Register any additional module middleware.
11
     *
12
     * @param  array|string  $middleware
13
	 * @return void
14
     */
15
	protected function addMiddleware($middleware)
16
	{
17
		$kernel = $this->app['Illuminate\Contracts\Http\Kernel'];
18
19
		if (is_array($middleware)) {
20
			foreach ($middleware as $ware) {
21
				$kernel->pushMiddleware($ware);
22
			}
23
		} else {
24
			$kernel->pushMiddleware($middleware);
25
		}
26
	}
27
}
28