Passed
Push — master ( ef81cd...93f366 )
by Faiq
04:39
created
app/Http/Middleware/EncryptCookies.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -4,8 +4,7 @@
 block discarded – undo
4 4
 
5 5
 use Illuminate\Cookie\Middleware\EncryptCookies as Middleware;
6 6
 
7
-class EncryptCookies extends Middleware
8
-{
7
+class EncryptCookies extends Middleware {
9 8
     /**
10 9
      * The names of the cookies that should not be encrypted.
11 10
      *
Please login to merge, or discard this patch.
app/Http/Middleware/VerifyCsrfToken.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -4,8 +4,7 @@
 block discarded – undo
4 4
 
5 5
 use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as Middleware;
6 6
 
7
-class VerifyCsrfToken extends Middleware
8
-{
7
+class VerifyCsrfToken extends Middleware {
9 8
     /**
10 9
      * Indicates whether the XSRF-TOKEN cookie should be set on the response.
11 10
      *
Please login to merge, or discard this patch.
app/Http/Middleware/TrimStrings.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -4,8 +4,7 @@
 block discarded – undo
4 4
 
5 5
 use Illuminate\Foundation\Http\Middleware\TrimStrings as Middleware;
6 6
 
7
-class TrimStrings extends Middleware
8
-{
7
+class TrimStrings extends Middleware {
9 8
     /**
10 9
      * The names of the attributes that should not be trimmed.
11 10
      *
Please login to merge, or discard this patch.
app/Http/Controllers/Controller.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,7 +7,6 @@
 block discarded – undo
7 7
 use Illuminate\Foundation\Validation\ValidatesRequests;
8 8
 use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
9 9
 
10
-class Controller extends BaseController
11
-{
10
+class Controller extends BaseController {
12 11
     use AuthorizesRequests, DispatchesJobs, ValidatesRequests;
13 12
 }
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/OAuthController.php 2 patches
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -10,8 +10,7 @@
 block discarded – undo
10 10
 use Illuminate\Validation\ValidationException;
11 11
 use Laravel\Socialite\Facades\Socialite;
12 12
 
13
-class OAuthController extends Controller
14
-{
13
+class OAuthController extends Controller {
15 14
 
16 15
     public function redirectToProvider($provider)
17 16
     {
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
         $user = null;
33 33
         $err = null;
34 34
 
35
-        if($provider == 'google') {
35
+        if ($provider == 'google') {
36 36
             $user = Socialite::driver($provider)->stateless()->user();
37 37
         } else {
38 38
             $user = Socialite::driver($provider)->user();
@@ -40,13 +40,13 @@  discard block
 block discarded – undo
40 40
 
41 41
         $authUser = $this->findOrCreateUser($user, $provider);
42 42
 
43
-        $attempt = Auth::guard('web')->attempt(['email' => $authUser->email, 'password' => $authUser->provider_id]);
43
+        $attempt = Auth::guard('web')->attempt([ 'email' => $authUser->email, 'password' => $authUser->provider_id ]);
44 44
 
45 45
         $req = new Request([
46 46
             'email' => $authUser->email,
47 47
         ]);
48 48
 
49
-        if($attempt) {
49
+        if ($attempt) {
50 50
             $msg = "Selamat Datang ".$authUser->name." !";
51 51
             return redirect()->intended(route('home'))->with('info', $msg);
52 52
         }
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
     private function findOrCreateUser($user, $provider)
66 66
     {
67 67
         $authUser = User::where('email', $user->getEmail())->first();
68
-        if($authUser) {
68
+        if ($authUser) {
69 69
             return $authUser;
70 70
         }
71 71
 
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
     private function sendFailedLoginResponse(Request $request)
85 85
     {
86 86
         throw ValidationException::withMessages([
87
-            'email' => [trans('auth.failed')],
87
+            'email' => [ trans('auth.failed') ],
88 88
         ]);
89 89
 
90 90
     }
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/VerificationController.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -5,8 +5,7 @@
 block discarded – undo
5 5
 use App\Http\Controllers\Controller;
6 6
 use Illuminate\Foundation\Auth\VerifiesEmails;
7 7
 
8
-class VerificationController extends Controller
9
-{
8
+class VerificationController extends Controller {
10 9
     /*
11 10
     |--------------------------------------------------------------------------
12 11
     | Email Verification Controller
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/ForgotPasswordController.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -5,8 +5,7 @@
 block discarded – undo
5 5
 use App\Http\Controllers\Controller;
6 6
 use Illuminate\Foundation\Auth\SendsPasswordResetEmails;
7 7
 
8
-class ForgotPasswordController extends Controller
9
-{
8
+class ForgotPasswordController extends Controller {
10 9
     /*
11 10
     |--------------------------------------------------------------------------
12 11
     | Password Reset Controller
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/LoginController.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -5,8 +5,7 @@
 block discarded – undo
5 5
 use App\Http\Controllers\Controller;
6 6
 use Illuminate\Foundation\Auth\AuthenticatesUsers;
7 7
 
8
-class LoginController extends Controller
9
-{
8
+class LoginController extends Controller {
10 9
     /*
11 10
     |--------------------------------------------------------------------------
12 11
     | Login Controller
Please login to merge, or discard this patch.
app/Http/Controllers/Auth/ResetPasswordController.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -5,8 +5,7 @@
 block discarded – undo
5 5
 use App\Http\Controllers\Controller;
6 6
 use Illuminate\Foundation\Auth\ResetsPasswords;
7 7
 
8
-class ResetPasswordController extends Controller
9
-{
8
+class ResetPasswordController extends Controller {
10 9
     /*
11 10
     |--------------------------------------------------------------------------
12 11
     | Password Reset Controller
Please login to merge, or discard this patch.