Passed
Push — master ( 788227...30d82e )
by Christopher
07:04
created
src/AssetCdnServiceProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
     {
31 31
         $this->mergeConfigFrom(__DIR__.'/../config/asset-cdn.php', 'asset-cdn');
32 32
 
33
-        $this->app->singleton(Finder::class, function ($app) {
33
+        $this->app->singleton(Finder::class, function($app) {
34 34
             return new Finder(new Config($app->make('config'), $app->make('path.public')));
35 35
         });
36 36
 
Please login to merge, or discard this patch.
src/Commands/SyncCommand.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
                     $config->get('asset-cdn.filesystem.options')
65 65
                 );
66 66
 
67
-            if (! $bool) {
67
+            if (!$bool) {
68 68
                 $this->error("Problem uploading: {$file->getRelativePathname()}");
69 69
             } else {
70 70
                 $this->info("Successfully uploaded: {$file->getRelativePathname()}");
@@ -87,9 +87,9 @@  discard block
 block discarded – undo
87 87
      */
88 88
     private function filesToSync(array $filesOnCdn, array $localFiles): array
89 89
     {
90
-        $array = array_filter($localFiles, function (SplFileInfo $localFile) use ($filesOnCdn) {
90
+        $array = array_filter($localFiles, function(SplFileInfo $localFile) use ($filesOnCdn) {
91 91
             $localFilePathname = $localFile->getRelativePathname();
92
-            if (! in_array($localFilePathname, $filesOnCdn)) {
92
+            if (!in_array($localFilePathname, $filesOnCdn)) {
93 93
                 return true;
94 94
             }
95 95
 
@@ -128,8 +128,8 @@  discard block
 block discarded – undo
128 128
     {
129 129
         $localFiles = $this->mapToPathname($localFiles);
130 130
 
131
-        $array = array_filter($filesOnCdn, function (string $fileOnCdn) use ($localFiles) {
132
-            return ! in_array($fileOnCdn, $localFiles);
131
+        $array = array_filter($filesOnCdn, function(string $fileOnCdn) use ($localFiles) {
132
+            return !in_array($fileOnCdn, $localFiles);
133 133
         });
134 134
 
135 135
         return array_values($array);
Please login to merge, or discard this patch.
src/Commands/PushCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@
 block discarded – undo
46 46
                     $config->get('asset-cdn.filesystem.options')
47 47
                 );
48 48
 
49
-            if (! $bool) {
49
+            if (!$bool) {
50 50
                 $this->error("Problem uploading: {$file->getRelativePathname()}");
51 51
             } else {
52 52
                 $this->info("Successfully uploaded: {$file->getRelativePathname()}");
Please login to merge, or discard this patch.
src/Commands/BaseCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@
 block discarded – undo
19 19
      */
20 20
     protected function mapToPathname(array $files): array
21 21
     {
22
-        return array_map(function (SplFileInfo $file) {
22
+        return array_map(function(SplFileInfo $file) {
23 23
             return $file->getRelativePathname();
24 24
         }, $files);
25 25
     }
Please login to merge, or discard this patch.
src/helpers.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
 use Illuminate\Support\Str;
4 4
 use Illuminate\Support\HtmlString;
5 5
 
6
-if (! function_exists('mix_cdn')) {
6
+if (!function_exists('mix_cdn')) {
7 7
     /**
8 8
      * Get the path to a versioned Mix file.
9 9
      *
@@ -15,24 +15,24 @@  discard block
 block discarded – undo
15 15
      */
16 16
     function mix_cdn($path, $manifestDirectory = '')
17 17
     {
18
-        if (! config('asset-cdn.use_cdn')) {
18
+        if (!config('asset-cdn.use_cdn')) {
19 19
             return mix($path, $manifestDirectory);
20 20
         }
21 21
 
22 22
         static $manifests = [];
23 23
 
24
-        if (! Str::startsWith($path, '/')) {
24
+        if (!Str::startsWith($path, '/')) {
25 25
             $path = "/{$path}";
26 26
         }
27 27
 
28
-        if ($manifestDirectory && ! Str::startsWith($manifestDirectory, '/')) {
28
+        if ($manifestDirectory && !Str::startsWith($manifestDirectory, '/')) {
29 29
             $manifestDirectory = "/{$manifestDirectory}";
30 30
         }
31 31
 
32 32
         $manifestPath = public_path($manifestDirectory.'/mix-manifest.json');
33 33
 
34
-        if (! isset($manifests[$manifestPath])) {
35
-            if (! file_exists($manifestPath)) {
34
+        if (!isset($manifests[$manifestPath])) {
35
+            if (!file_exists($manifestPath)) {
36 36
                 throw new Exception('The Mix manifest does not exist.');
37 37
             }
38 38
 
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
 
42 42
         $manifest = $manifests[$manifestPath];
43 43
 
44
-        if (! isset($manifest[$path])) {
44
+        if (!isset($manifest[$path])) {
45 45
             throw new Exception("Unable to locate Mix file: {$path}.");
46 46
         }
47 47
 
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
     }
54 54
 }
55 55
 
56
-if (! function_exists('asset_cdn')) {
56
+if (!function_exists('asset_cdn')) {
57 57
 
58 58
     /**
59 59
      * Generate an asset path for the application.
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
      */
64 64
     function asset_cdn($path)
65 65
     {
66
-        if (! config('asset-cdn.use_cdn')) {
66
+        if (!config('asset-cdn.use_cdn')) {
67 67
             return asset($path);
68 68
         }
69 69
 
Please login to merge, or discard this patch.
src/Finder.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -160,7 +160,7 @@
 block discarded – undo
160 160
     private function mergeFileInfos(array $includedPaths, array $includedNames): array
161 161
     {
162 162
         return collect(array_merge($includedPaths, $includedNames))
163
-            ->unique(function (SplFileInfo $file) {
163
+            ->unique(function(SplFileInfo $file) {
164 164
                 return $file->getPathname();
165 165
             })
166 166
             ->values()
Please login to merge, or discard this patch.
src/Config.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
     private function paths(string $type): array
83 83
     {
84 84
         return array_map(
85
-            function ($path) {
85
+            function($path) {
86 86
                 return $this->cleanPath($path).'/';
87 87
             },
88 88
             $this->config[$type]['paths']
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
     private function files(string $type): array
93 93
     {
94 94
         return array_map(
95
-            function ($path) {
95
+            function($path) {
96 96
                 return $this->cleanPath($path);
97 97
             },
98 98
             $this->config[$type]['files']
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
     private function extensions(string $type): array
103 103
     {
104 104
         return array_map(
105
-            function ($extension) {
105
+            function($extension) {
106 106
                 return '*'.$this->start($extension, '.');
107 107
             },
108 108
             $this->config[$type]['extensions']
Please login to merge, or discard this patch.