Passed
Push — master ( 2222c4...2fde46 )
by meta
02:37
created
src/ServiceProvider.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
         // Make sure nobody is including or running this thing without all the required env settings
17 17
         if (config('enterpriseauth')) {
18 18
             foreach (config('enterpriseauth.credentials') as $config => $env) {
19
-                if (! config('enterpriseauth.credentials.'.$config)) {
19
+                if (!config('enterpriseauth.credentials.'.$config)) {
20 20
                     throw new \Exception('enterpriseauth setup error: missing mandatory config value for enterpriseauth.credentials.'.$config.' check your .env file!');
21 21
                 }
22 22
             }
@@ -24,19 +24,19 @@  discard block
 block discarded – undo
24 24
 
25 25
         // Actually I have my own oauth token cache based authentication guard now lol
26 26
         config(['auth.guards.api.driver' => 'oauthtoken']);
27
-        Auth::extend('oauthtoken', function ($app, $name, array $config) {
27
+        Auth::extend('oauthtoken', function($app, $name, array $config) {
28 28
             return new \Metaclassing\EnterpriseAuth\Middleware\OauthTokenGuard(Auth::createUserProvider($config['provider']), $app->make('request'));
29 29
         });
30 30
 
31 31
         // Make sure that this vendor dir and the routes dir are in any scanned paths for swagger documentation
32 32
         $swaggerScanPaths = config('l5-swagger.paths.annotations');
33
-        if (! is_array($swaggerScanPaths)) {
33
+        if (!is_array($swaggerScanPaths)) {
34 34
             $swaggerScanPaths = [$swaggerScanPaths];
35 35
         }
36
-        if (! in_array(base_path('routes'), $swaggerScanPaths)) {
36
+        if (!in_array(base_path('routes'), $swaggerScanPaths)) {
37 37
             $swaggerScanPaths[] = base_path('routes');
38 38
         }
39
-        if (! in_array(__DIR__.'/../routes/', $swaggerScanPaths)) {
39
+        if (!in_array(__DIR__.'/../routes/', $swaggerScanPaths)) {
40 40
             $swaggerScanPaths[] = __DIR__.'/../routes/';
41 41
         }
42 42
         config(['l5-swagger.paths.annotations' => $swaggerScanPaths]);
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
     {
67 67
         // If the routes files for the swagger oauth config is NOT present, and we have all the right info, then generate it really quick
68 68
         $swaggerAzureadFile = __DIR__.'/../routes/swagger.azuread.php';
69
-        if (! file_exists($swaggerAzureadFile)) {
69
+        if (!file_exists($swaggerAzureadFile)) {
70 70
             $aad = new AzureActiveDirectory(config('enterpriseauth.credentials.tenant'));
71 71
             //$authorizationUrl = $aad->authorizationEndpoint . '?resource=https://graph.microsoft.com';
72 72
             $authorizationUrl = $aad->authorizationEndpoint;
Please login to merge, or discard this patch.