@@ -23,7 +23,7 @@ |
||
23 | 23 | */ |
24 | 24 | public function register() |
25 | 25 | { |
26 | - $this->app->singleton('flash', function () { |
|
26 | + $this->app->singleton('flash', function() { |
|
27 | 27 | return $this->app->make(\App\Session\FlashMessage::class); |
28 | 28 | }); |
29 | 29 | } |
@@ -20,7 +20,7 @@ |
||
20 | 20 | { |
21 | 21 | Schema::defaultStringLength(191); |
22 | 22 | |
23 | - Route::bind('link_hash', function ($hash = '') { |
|
23 | + Route::bind('link_hash', function($hash = '') { |
|
24 | 24 | return Link::where('hash', $hash)->first(); |
25 | 25 | }); |
26 | 26 | } |
@@ -35,7 +35,7 @@ |
||
35 | 35 | } |
36 | 36 | |
37 | 37 | // Allow access only to administrators |
38 | - if (! $this->auth->user()->hasRole('Administrator')) { |
|
38 | + if ( ! $this->auth->user()->hasRole('Administrator')) { |
|
39 | 39 | abort(404, 'You are not authorized to view requested resource.'); |
40 | 40 | |
41 | 41 | return redirect()->route('homepage'); |
@@ -13,6 +13,6 @@ |
||
13 | 13 | | |
14 | 14 | */ |
15 | 15 | |
16 | -Artisan::command('inspire', function () { |
|
16 | +Artisan::command('inspire', function() { |
|
17 | 17 | $this->comment(Inspiring::quote()); |
18 | 18 | })->describe('Display an inspiring quote'); |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | |
20 | 20 | Route::get('/logout', ['as' => 'user.logout', 'uses' => 'Auth\LoginController@logout']); |
21 | 21 | |
22 | -Route::get('/home', function () { |
|
22 | +Route::get('/home', function() { |
|
23 | 23 | return redirect()->route('url_create'); |
24 | 24 | })->middleware('auth')->name('home'); |
25 | 25 | |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | Route::group([ |
30 | 30 | 'prefix' => '/admin', |
31 | 31 | 'middleware' => ['auth'], |
32 | -], function () { |
|
32 | +], function() { |
|
33 | 33 | //LinksController |
34 | 34 | //UsersController |
35 | 35 | }); |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | Route::group([ |
41 | 41 | 'prefix' => '/dashboard', |
42 | 42 | 'middleware' => ['auth'], |
43 | -], function () { |
|
43 | +], function() { |
|
44 | 44 | Route::resource('links', 'UserDashboardController'); |
45 | 45 | }); |
46 | 46 |
@@ -11,6 +11,6 @@ |
||
11 | 11 | | |
12 | 12 | */ |
13 | 13 | |
14 | -Broadcast::channel('App.User.{id}', function ($user, $id) { |
|
14 | +Broadcast::channel('App.User.{id}', function($user, $id) { |
|
15 | 15 | return (int) $user->id === (int) $id; |
16 | 16 | }); |
@@ -13,6 +13,6 @@ |
||
13 | 13 | | |
14 | 14 | */ |
15 | 15 | |
16 | -Route::middleware('auth:api')->get('/user', function (Request $request) { |
|
16 | +Route::middleware('auth:api')->get('/user', function(Request $request) { |
|
17 | 17 | return $request->user(); |
18 | 18 | }); |
@@ -12,7 +12,7 @@ discard block |
||
12 | 12 | */ |
13 | 13 | |
14 | 14 | /** @var \Illuminate\Database\Eloquent\Factory $factory */ |
15 | -$factory->define(App\User::class, function (Faker\Generator $faker) { |
|
15 | +$factory->define(App\User::class, function(Faker\Generator $faker) { |
|
16 | 16 | static $password; |
17 | 17 | |
18 | 18 | return [ |
@@ -23,7 +23,7 @@ discard block |
||
23 | 23 | ]; |
24 | 24 | }); |
25 | 25 | |
26 | -$factory->define(App\Role::class, function (Faker\Generator $faker) { |
|
26 | +$factory->define(App\Role::class, function(Faker\Generator $faker) { |
|
27 | 27 | return [ |
28 | 28 | 'name' => 'Administrator', |
29 | 29 | ]; |
@@ -13,7 +13,7 @@ |
||
13 | 13 | */ |
14 | 14 | public function up() |
15 | 15 | { |
16 | - Schema::create('users', function (Blueprint $table) { |
|
16 | + Schema::create('users', function(Blueprint $table) { |
|
17 | 17 | $table->increments('id'); |
18 | 18 | $table->string('name'); |
19 | 19 | $table->string('email')->unique(); |