@@ -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(); |
@@ -13,7 +13,7 @@ |
||
13 | 13 | */ |
14 | 14 | public function up() |
15 | 15 | { |
16 | - Schema::create('password_resets', function (Blueprint $table) { |
|
16 | + Schema::create('password_resets', function(Blueprint $table) { |
|
17 | 17 | $table->string('email')->index(); |
18 | 18 | $table->string('token')->index(); |
19 | 19 | $table->timestamp('created_at')->nullable(); |
@@ -13,7 +13,7 @@ |
||
13 | 13 | */ |
14 | 14 | public function up() |
15 | 15 | { |
16 | - Schema::create('links', function (Blueprint $table) { |
|
16 | + Schema::create('links', function(Blueprint $table) { |
|
17 | 17 | $table->increments('id'); |
18 | 18 | $table->unsignedInteger('user_id')->nullable(); |
19 | 19 | $table->string('url'); |
@@ -13,7 +13,7 @@ discard block |
||
13 | 13 | */ |
14 | 14 | public function up() |
15 | 15 | { |
16 | - Schema::create('role_user', function (Blueprint $table) { |
|
16 | + Schema::create('role_user', function(Blueprint $table) { |
|
17 | 17 | $table->increments('id'); |
18 | 18 | $table->integer('user_id')->unsigned()->index(); |
19 | 19 | $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade'); |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | */ |
31 | 31 | public function down() |
32 | 32 | { |
33 | - Schema::table('role_user', function (Blueprint $table) { |
|
33 | + Schema::table('role_user', function(Blueprint $table) { |
|
34 | 34 | Schema::drop('role_user'); |
35 | 35 | }); |
36 | 36 | } |
@@ -13,7 +13,7 @@ discard block |
||
13 | 13 | */ |
14 | 14 | public function up() |
15 | 15 | { |
16 | - Schema::create('roles', function (Blueprint $table) { |
|
16 | + Schema::create('roles', function(Blueprint $table) { |
|
17 | 17 | $table->increments('id'); |
18 | 18 | $table->text('name'); |
19 | 19 | $table->timestamps(); |
@@ -27,7 +27,7 @@ discard block |
||
27 | 27 | */ |
28 | 28 | public function down() |
29 | 29 | { |
30 | - Schema::table('roles', function (Blueprint $table) { |
|
30 | + Schema::table('roles', function(Blueprint $table) { |
|
31 | 31 | Schema::drop('roles'); |
32 | 32 | }); |
33 | 33 | } |
@@ -13,7 +13,7 @@ |
||
13 | 13 | */ |
14 | 14 | public function up() |
15 | 15 | { |
16 | - Schema::create('hits', function (Blueprint $table) { |
|
16 | + Schema::create('hits', function(Blueprint $table) { |
|
17 | 17 | $table->increments('id'); |
18 | 18 | $table->integer('link_id')->unsigned()->nullable(); |
19 | 19 | $table->string('ip')->nullable(); |