@@ -58,7 +58,7 @@ |
||
| 58 | 58 | } |
| 59 | 59 | |
| 60 | 60 | if (!$user->can('read all recruitments')) { |
| 61 | - $filtered = $candidates->filter(function ($candidate, $key) use ($user) { |
|
| 61 | + $filtered = $candidates->filter(function($candidate, $key) use ($user) { |
|
| 62 | 62 | return $user->can('view', $candidate); |
| 63 | 63 | } |
| 64 | 64 | ); |
@@ -22,6 +22,6 @@ |
||
| 22 | 22 | $note->save(); |
| 23 | 23 | |
| 24 | 24 | $note = Note::with('user')->find($note->id); |
| 25 | - return response()->json($note, 201, ['Location'=>'/notes/'.$note->id]); |
|
| 25 | + return response()->json($note, 201, ['Location'=>'/notes/' . $note->id]); |
|
| 26 | 26 | } |
| 27 | 27 | } |
@@ -12,7 +12,7 @@ |
||
| 12 | 12 | */ |
| 13 | 13 | protected function registerDatabaseConnector($manager) |
| 14 | 14 | { |
| 15 | - $manager->addConnector('database', function () { |
|
| 15 | + $manager->addConnector('database', function() { |
|
| 16 | 16 | return new DatabaseConnector($this->app['db']); |
| 17 | 17 | }); |
| 18 | 18 | } |
@@ -35,7 +35,7 @@ |
||
| 35 | 35 | */ |
| 36 | 36 | protected function commands() |
| 37 | 37 | { |
| 38 | - $this->load(__DIR__.'/Commands'); |
|
| 38 | + $this->load(__DIR__ . '/Commands'); |
|
| 39 | 39 | |
| 40 | 40 | require base_path('routes/console.php'); |
| 41 | 41 | } |
@@ -53,10 +53,10 @@ discard block |
||
| 53 | 53 | $tenant = Tenant::find($tenantId); |
| 54 | 54 | |
| 55 | 55 | if (!$tenant) { |
| 56 | - throw new RuntimeException('Tenant with ID = '.$tenantId.' does not exist.'); |
|
| 56 | + throw new RuntimeException('Tenant with ID = ' . $tenantId . ' does not exist.'); |
|
| 57 | 57 | } |
| 58 | 58 | |
| 59 | - $this->comment('Creating new user for tenant with subdomain \''.$tenant->subdomain.'\'.'); |
|
| 59 | + $this->comment('Creating new user for tenant with subdomain \'' . $tenant->subdomain . '\'.'); |
|
| 60 | 60 | |
| 61 | 61 | $email = $this->option('email'); |
| 62 | 62 | if (!$email) { |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | |
| 66 | 66 | $num = TenantUser::where('username', $email)->count(); |
| 67 | 67 | if ($num) { |
| 68 | - throw new RuntimeException('User with email \''.$email.'\' already exists.'); |
|
| 68 | + throw new RuntimeException('User with email \'' . $email . '\' already exists.'); |
|
| 69 | 69 | } |
| 70 | 70 | |
| 71 | 71 | $name = $this->option('name'); |
@@ -90,7 +90,7 @@ discard block |
||
| 90 | 90 | |
| 91 | 91 | $user->assignRole('super-admin'); |
| 92 | 92 | |
| 93 | - DB::transaction(function () use ($tenantUser, $user) { |
|
| 93 | + DB::transaction(function() use ($tenantUser, $user) { |
|
| 94 | 94 | $tenantUser->save(); |
| 95 | 95 | $user->save(); |
| 96 | 96 | }); |
@@ -48,7 +48,7 @@ discard block |
||
| 48 | 48 | $tenant = Tenant::find($tenantId); |
| 49 | 49 | |
| 50 | 50 | if (!$tenant) { |
| 51 | - throw new RuntimeException('Tenant with ID = '.$tenantId.' does not exist.'); |
|
| 51 | + throw new RuntimeException('Tenant with ID = ' . $tenantId . ' does not exist.'); |
|
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | $this->tenantManager->setTenant($tenant); |
@@ -70,6 +70,6 @@ discard block |
||
| 70 | 70 | $seeder->setConnection('tenant'); |
| 71 | 71 | $seeder->run(); |
| 72 | 72 | |
| 73 | - $this->info('Demo data have been seeded for tenant with subdomain \''.$tenant->subdomain.'\'.'); |
|
| 73 | + $this->info('Demo data have been seeded for tenant with subdomain \'' . $tenant->subdomain . '\'.'); |
|
| 74 | 74 | } |
| 75 | 75 | } |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | $tenantUser->username = $user->email; |
| 35 | 35 | $tenantUser->tenant_id = $tenant->id; |
| 36 | 36 | |
| 37 | - DB::transaction(function () use ($tenantUser, $user, $invitation) { |
|
| 37 | + DB::transaction(function() use ($tenantUser, $user, $invitation) { |
|
| 38 | 38 | $tenantUser->save(); |
| 39 | 39 | $user->save(); |
| 40 | 40 | $invitation->save(); |
@@ -70,7 +70,7 @@ discard block |
||
| 70 | 70 | |
| 71 | 71 | $invitation->token = null; |
| 72 | 72 | |
| 73 | - DB::transaction(function () use ($user, $invitation) { |
|
| 73 | + DB::transaction(function() use ($user, $invitation) { |
|
| 74 | 74 | $user->save(); |
| 75 | 75 | $invitation->save(); |
| 76 | 76 | }); |
@@ -17,11 +17,11 @@ |
||
| 17 | 17 | $manager = new TenantManager(); |
| 18 | 18 | |
| 19 | 19 | $this->app->instance(TenantManager::class, $manager); |
| 20 | - $this->app->bind(Tenant::class, function () use ($manager) { |
|
| 20 | + $this->app->bind(Tenant::class, function() use ($manager) { |
|
| 21 | 21 | return $manager->getTenant(); |
| 22 | 22 | }); |
| 23 | 23 | |
| 24 | - $this->app['db']->extend('tenant', function ($config, $name) use ($manager) { |
|
| 24 | + $this->app['db']->extend('tenant', function($config, $name) use ($manager) { |
|
| 25 | 25 | $tenant = $manager->getTenant(); |
| 26 | 26 | |
| 27 | 27 | if ($tenant) { |