Passed
Branch main (999baf)
by Salah
12:12
created
src/Collection.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
      */
25 25
     public function toArray()
26 26
     {
27
-        return array_map(function ($value) {
27
+        return array_map(function($value) {
28 28
             if ($value instanceof Domain) {
29 29
                 $attributes = $value->json()->getAttributes();
30 30
                 $attributes["path"] = $value->getPath();
Please login to merge, or discard this patch.
src/Migrations/Migrator.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -97,7 +97,7 @@  discard block
 block discarded – undo
97 97
             return [];
98 98
         }
99 99
 
100
-        $files = array_map(function ($file) {
100
+        $files = array_map(function($file) {
101 101
             return str_replace('.php', '', basename($file));
102 102
         }, $files);
103 103
 
@@ -301,7 +301,7 @@  discard block
 block discarded – undo
301 301
 
302 302
         $result = $query->orderBy('migration', 'desc')->get();
303 303
 
304
-        return collect($result)->map(function ($item) {
304
+        return collect($result)->map(function($item) {
305 305
             return (array) $item;
306 306
         })->pluck('migration');
307 307
     }
Please login to merge, or discard this patch.
src/Json.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -130,7 +130,7 @@
 block discarded – undo
130 130
             return $attributes;
131 131
         }
132 132
 
133
-        return app('cache')->store(config('domains.cache.driver'))->remember($this->getPath(), config('domains.cache.lifetime'), function () use ($attributes) {
133
+        return app('cache')->store(config('domains.cache.driver'))->remember($this->getPath(), config('domains.cache.lifetime'), function() use ($attributes) {
134 134
             return $attributes;
135 135
         });
136 136
     }
Please login to merge, or discard this patch.
src/helpers.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -3,7 +3,7 @@  discard block
 block discarded – undo
3 3
 use Illuminate\Foundation\Vite;
4 4
 use Illuminate\Support\Facades\Vite as ViteFacade;
5 5
 
6
-if (! function_exists('domain_path')) {
6
+if (!function_exists('domain_path')) {
7 7
     function domain_path($name, $path = '')
8 8
     {
9 9
         $domain = app('domains')->find($name);
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
     }
13 13
 }
14 14
 
15
-if (! function_exists('config_path')) {
15
+if (!function_exists('config_path')) {
16 16
     /**
17 17
      * Get the configuration path.
18 18
      *
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
     }
26 26
 }
27 27
 
28
-if (! function_exists('public_path')) {
28
+if (!function_exists('public_path')) {
29 29
     /**
30 30
      * Get the path to the public folder.
31 31
      *
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
     }
39 39
 }
40 40
 
41
-if (! function_exists('domain_vite')) {
41
+if (!function_exists('domain_vite')) {
42 42
     /**
43 43
      * support for vite
44 44
      */
Please login to merge, or discard this patch.
src/Commands/PresenterCommand.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -46,7 +46,7 @@  discard block
 block discarded – undo
46 46
      * @see fire()
47 47
      * @return void
48 48
      */
49
-    public function handle(){
49
+    public function handle() {
50 50
         $this->laravel->call([$this, 'fire'], func_get_args());
51 51
     }
52 52
 
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
     {
60 60
 
61 61
         try {
62
-            if($this->argument('domain') && $this->argument('domain-path')) {
62
+            if ($this->argument('domain') && $this->argument('domain-path')) {
63 63
                 $domain = $this->argument('domain');
64 64
                 $domainPath = $this->argument('domain-path');
65 65
             } else {
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
             (new PresenterGenerator([
71 71
                 'name'  => $this->argument('name'),
72 72
                 'force' => $this->option('force'),
73
-            ],$domain,$domainPath))->run();
73
+            ], $domain, $domainPath))->run();
74 74
             $this->info("Presenter created successfully.");
75 75
 
76 76
             if (!\File::exists(app()->path() . '/Transformers/' . $this->argument('name') . 'Transformer.php')) {
@@ -78,7 +78,7 @@  discard block
 block discarded – undo
78 78
                     (new TransformerGenerator([
79 79
                         'name'  => $this->argument('name'),
80 80
                         'force' => $this->option('force'),
81
-                    ],$domain,$domainPath))->run();
81
+                    ], $domain, $domainPath))->run();
82 82
                     $this->info("Transformer created successfully.");
83 83
                 }
84 84
             }
Please login to merge, or discard this patch.
src/Commands/DumpCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
     {
30 30
         $this->components->info('Generating optimized autoload domains.');
31 31
 
32
-        if ($name = $this->argument('domain') ) {
32
+        if ($name = $this->argument('domain')) {
33 33
             $this->dump($name);
34 34
 
35 35
             return 0;
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
             $domain = $this->laravel['domains']->findOrFail($name);
64 64
         }
65 65
 
66
-        $this->components->task("$domain", function () use ($domain) {
66
+        $this->components->task("$domain", function() use ($domain) {
67 67
             chdir($domain->getPath());
68 68
 
69 69
             passthru('composer dump -o -n -q');
Please login to merge, or discard this patch.
src/Commands/DisableCommand.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@  discard block
 block discarded – undo
29 29
     {
30 30
         $this->components->info('Disabling domain ...');
31 31
 
32
-        if ($name = $this->argument('domain') ) {
32
+        if ($name = $this->argument('domain')) {
33 33
             $this->disable($name);
34 34
 
35 35
             return 0;
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
     {
66 66
         if ($name instanceof Domain) {
67 67
             $domain = $name;
68
-        }else {
68
+        } else {
69 69
             $domain = $this->laravel['domains']->findOrFail($name);
70 70
         }
71 71
 
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -65,7 +65,7 @@
 block discarded – undo
65 65
     {
66 66
         if ($name instanceof Domain) {
67 67
             $domain = $name;
68
-        }else {
68
+        } else {
69 69
             $domain = $this->laravel['domains']->findOrFail($name);
70 70
         }
71 71
 
Please login to merge, or discard this patch.
src/Commands/ComponentClassMakeCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,7 @@
 block discarded – undo
49 49
      */
50 50
     protected function writeComponentViewTemplate()
51 51
     {
52
-        $this->call('domain:make-component-view', ['name' => $this->argument('name') , 'domain' => $this->argument('domain')]);
52
+        $this->call('domain:make-component-view', ['name' => $this->argument('name'), 'domain' => $this->argument('domain')]);
53 53
     }
54 54
 
55 55
     public function getDefaultNamespace(): string
Please login to merge, or discard this patch.
src/Commands/ValidatorCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
      * @see fire()
49 49
      * @return void
50 50
      */
51
-    public function handle(){
51
+    public function handle() {
52 52
         $this->laravel->call([$this, 'fire'], func_get_args());
53 53
     }
54 54
 
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
      */
60 60
     public function fire()
61 61
     {
62
-        if($this->argument('domain') && $this->argument('domain-path')) {
62
+        if ($this->argument('domain') && $this->argument('domain-path')) {
63 63
             $domain = $this->argument('domain');
64 64
             $domainPath = $this->argument('domain-path');
65 65
             
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
                 'name' => $this->argument('name'),
73 73
                 'rules' => $this->option('rules'),
74 74
                 'force' => $this->option('force'),
75
-            ],$domain,$domainPath))->run();
75
+            ], $domain, $domainPath))->run();
76 76
             $this->info("Validator created successfully.");
77 77
         } catch (FileAlreadyExistsException $e) {
78 78
             $this->error($this->type . ' already exists!');
Please login to merge, or discard this patch.