BusServiceProvider::boot()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 9
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 9
rs 9.6666
cc 1
eloc 4
nc 1
nop 1
1
<?php namespace App\Providers;
2
3
use Illuminate\Bus\Dispatcher;
4
use Illuminate\Support\ServiceProvider;
5
6
class BusServiceProvider extends ServiceProvider {
7
8
	/**
9
	 * Bootstrap any application services.
10
	 *
11
	 * @param  \Illuminate\Bus\Dispatcher  $dispatcher
12
	 * @return void
13
	 */
14
	public function boot(Dispatcher $dispatcher)
15
	{
16
		$dispatcher->mapUsing(function($command)
17
		{
18
			return Dispatcher::simpleMapping(
19
				$command, 'App\Commands', 'App\Handlers\Commands'
20
			);
21
		});
22
	}
23
24
	/**
25
	 * Register any application services.
26
	 *
27
	 * @return void
28
	 */
29
	public function register()
30
	{
31
		//
32
	}
33
34
}
35