Passed
Push — master ( 1cc4f4...5ea905 )
by meta
02:43
created
src/Controllers/WebAuthController.php 1 patch
Indentation   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -39,8 +39,8 @@  discard block
 block discarded – undo
39 39
     public function buildAuthUrl()
40 40
     {
41 41
         $url = $this->azureActiveDirectory->authorizationEndpoint
42
-             .'?'
43
-             .$this->buildAuthUrlQueryString();
42
+                .'?'
43
+                .$this->buildAuthUrlQueryString();
44 44
 
45 45
         return $url;
46 46
     }
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
 
71 71
         // Check to see if there is an intended destination url saved
72 72
         $destination = $request->session()
73
-                               ->get('oauthIntendedUrl');
73
+                                ->get('oauthIntendedUrl');
74 74
         // If there is no intended destination url, use the default
75 75
         if (! $destination) {
76 76
             $destination = config('enterpriseauth.redirect_on_login');
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
                 'client_secret' => config('enterpriseauth.credentials.client_secret'),
97 97
                 'redirect_uri'  => config('enterpriseauth.credentials.callback_url'),
98 98
                 'grant_type'    => 'authorization_code',
99
-             ],
99
+                ],
100 100
         ];
101 101
         $response = $guzzle->post($url, $parameters);
102 102
         $responseObject = json_decode($response->getBody());
Please login to merge, or discard this patch.
src/ServiceProvider.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -15,26 +15,26 @@  discard block
 block discarded – undo
15 15
     {
16 16
         // Make sure nobody is including or running this thing without all the required env settings
17 17
         foreach (config('enterpriseauth.credentials') as $config => $env) {
18
-            if (! config('enterpriseauth.credentials.'.$config)) {
18
+            if (!config('enterpriseauth.credentials.'.$config)) {
19 19
                 throw new \Exception('enterpriseauth setup error: missing mandatory config value for enterpriseauth.credentials.'.$config.' check your .env file!');
20 20
             }
21 21
         }
22 22
 
23 23
         // Actually I have my own oauth token cache based authentication guard now lol
24 24
         config(['auth.guards.api.driver' => 'oauthtoken']);
25
-        Auth::extend('oauthtoken', function ($app, $name, array $config) {
25
+        Auth::extend('oauthtoken', function($app, $name, array $config) {
26 26
             return new \Metaclassing\EnterpriseAuth\Middleware\OauthTokenGuard(Auth::createUserProvider($config['provider']), $app->make('request'));
27 27
         });
28 28
 
29 29
         // Make sure that this vendor dir and the routes dir are in any scanned paths for swagger documentation
30 30
         $swaggerScanPaths = config('l5-swagger.paths.annotations');
31
-        if (! is_array($swaggerScanPaths)) {
31
+        if (!is_array($swaggerScanPaths)) {
32 32
             $swaggerScanPaths = [$swaggerScanPaths];
33 33
         }
34
-        if (! in_array(base_path('routes'), $swaggerScanPaths)) {
34
+        if (!in_array(base_path('routes'), $swaggerScanPaths)) {
35 35
             $swaggerScanPaths[] = base_path('routes');
36 36
         }
37
-        if (! in_array(__DIR__.'/../routes/', $swaggerScanPaths)) {
37
+        if (!in_array(__DIR__.'/../routes/', $swaggerScanPaths)) {
38 38
             $swaggerScanPaths[] = __DIR__.'/../routes/';
39 39
         }
40 40
         config(['l5-swagger.paths.annotations' => $swaggerScanPaths]);
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
     {
65 65
         // If the routes files for the swagger oauth config is NOT present, and we have all the right info, then generate it really quick
66 66
         $swaggerAzureadFile = __DIR__.'/../routes/swagger.azuread.php';
67
-        if (! file_exists($swaggerAzureadFile)) {
67
+        if (!file_exists($swaggerAzureadFile)) {
68 68
             $aad = new AzureActiveDirectory(config('enterpriseauth.credentials.tenant'));
69 69
             //$authorizationUrl = $aad->authorizationEndpoint . '?resource=https://graph.microsoft.com';
70 70
             $authorizationUrl = $aad->authorizationEndpoint;
Please login to merge, or discard this patch.