Passed
Pull Request — main (#3)
by PRATIK
12:38 queued 04:57
created
src/Models/Admin/Preference.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,11 +15,11 @@
 block discarded – undo
15 15
     {
16 16
         parent::boot();
17 17
 
18
-        static::saving(function () {
18
+        static::saving(function() {
19 19
             self::cacheKey();
20 20
         });
21 21
 
22
-        static::deleting(function () {
22
+        static::deleting(function() {
23 23
             self::cacheKey();
24 24
         });
25 25
     }
Please login to merge, or discard this patch.
src/Models/Admin/Permission.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,11 +15,11 @@
 block discarded – undo
15 15
     {
16 16
         parent::boot();
17 17
 
18
-        static::saving(function () {
18
+        static::saving(function() {
19 19
             self::cacheKey();
20 20
         });
21 21
 
22
-        static::deleting(function () {
22
+        static::deleting(function() {
23 23
             self::cacheKey();
24 24
         });
25 25
     }
Please login to merge, or discard this patch.
src/Models/Admin/Role.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,11 +15,11 @@
 block discarded – undo
15 15
     {
16 16
         parent::boot();
17 17
 
18
-        static::saving(function () {
18
+        static::saving(function() {
19 19
             self::cacheKey();
20 20
         });
21 21
 
22
-        static::deleting(function () {
22
+        static::deleting(function() {
23 23
             self::cacheKey();
24 24
         });
25 25
     }
Please login to merge, or discard this patch.
src/Helpers/AdminHelper.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-if (! function_exists('getClassesList')) {
3
+if (!function_exists('getClassesList')) {
4 4
     function getClassesList($dir)
5 5
     {
6 6
         $classes = \File::allFiles($dir);
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
         return $classes;
16 16
     }
17 17
 }
18
-if (! function_exists('getAllModelNames')) {
18
+if (!function_exists('getAllModelNames')) {
19 19
     function getAllModelNames($dir)
20 20
     {
21 21
         $modelNames = [];
@@ -29,42 +29,42 @@  discard block
 block discarded – undo
29 29
     }
30 30
 }
31 31
 
32
-if (! function_exists('validImageFolder')) {
32
+if (!function_exists('validImageFolder')) {
33 33
     function validImageFolder($name, $default = 'default')
34 34
     {
35 35
         return strtolower(str_replace([' ', '-', '$', '<', '>', '&', '{', '}', '*', '\\', '/', ':', '.', ';', ',', "'", '"'], '_', $name ?? trim($default)));
36 36
     }
37 37
 }
38 38
 
39
-if (! function_exists('getImagePlaceholder')) {
39
+if (!function_exists('getImagePlaceholder')) {
40 40
     function getImagePlaceholder()
41 41
     {
42 42
         return asset('adminetic/static/placeholder.png');
43 43
     }
44 44
 }
45 45
 
46
-if (! function_exists('getVerticalImagePlaceholder')) {
46
+if (!function_exists('getVerticalImagePlaceholder')) {
47 47
     function getVerticalImagePlaceholder()
48 48
     {
49 49
         return asset('adminetic/static/vertical_placeholder.jpg');
50 50
     }
51 51
 }
52 52
 
53
-if (! function_exists('getSliderPlaceholder')) {
53
+if (!function_exists('getSliderPlaceholder')) {
54 54
     function getSliderPlaceholder()
55 55
     {
56 56
         return asset('adminetic/static/slider.jpg');
57 57
     }
58 58
 }
59 59
 
60
-if (! function_exists('getFoodImagePlaceholder')) {
60
+if (!function_exists('getFoodImagePlaceholder')) {
61 61
     function getFoodImagePlaceholder()
62 62
     {
63 63
         return asset('adminetic/static/food_placeholder.jpg');
64 64
     }
65 65
 }
66 66
 
67
-if (! function_exists('getProfilePlaceholder')) {
67
+if (!function_exists('getProfilePlaceholder')) {
68 68
     function getProfilePlaceholder($p = null)
69 69
     {
70 70
         $profile = $p ?? Auth::user()->profile;
@@ -73,48 +73,48 @@  discard block
 block discarded – undo
73 73
     }
74 74
 }
75 75
 
76
-if (! function_exists('getFavicon')) {
76
+if (!function_exists('getFavicon')) {
77 77
     function getFavicon()
78 78
     {
79 79
         return setting('favicon') ? (asset('storage/'.setting('favicon'))) : 'adminetic/static/favicon.png';
80 80
     }
81 81
 }
82
-if (! function_exists('getLogo')) {
82
+if (!function_exists('getLogo')) {
83 83
     function getLogo()
84 84
     {
85 85
         return setting('logo') ? (asset('storage/'.setting('logo'))) : 'adminetic/static/logo.png';
86 86
     }
87 87
 }
88 88
 
89
-if (! function_exists('getLogoBanner')) {
89
+if (!function_exists('getLogoBanner')) {
90 90
     function getLogoBanner()
91 91
     {
92 92
         return setting('logo_banner') ? (asset('storage/'.setting('logo_banner'))) : 'adminetic/static/logo_banner.jpg';
93 93
     }
94 94
 }
95 95
 
96
-if (! function_exists('getLazyLoadImg')) {
96
+if (!function_exists('getLazyLoadImg')) {
97 97
     function getLazyLoadImg()
98 98
     {
99 99
         return asset('website/assets/images/image-bg.svg');
100 100
     }
101 101
 }
102 102
 
103
-if (! function_exists('random_color_part')) {
103
+if (!function_exists('random_color_part')) {
104 104
     function random_color_part()
105 105
     {
106 106
         return str_pad(dechex(mt_rand(0, 255)), 2, '0', STR_PAD_LEFT);
107 107
     }
108 108
 }
109 109
 
110
-if (! function_exists('random_color')) {
110
+if (!function_exists('random_color')) {
111 111
     function random_color()
112 112
     {
113 113
         return random_color_part().random_color_part().random_color_part();
114 114
     }
115 115
 }
116 116
 
117
-if (! function_exists('setting')) {
117
+if (!function_exists('setting')) {
118 118
     function setting($setting_name, $default = null)
119 119
     {
120 120
         $valid_setting_name = strtolower(str_replace(' ', '_', $setting_name));
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
     }
125 125
 }
126 126
 
127
-if (! function_exists('preference')) {
127
+if (!function_exists('preference')) {
128 128
     function preference($preference_name, bool $default = null)
129 129
     {
130 130
         $valid_preference_name = strtolower(str_replace(' ', '_', $preference_name));
@@ -138,11 +138,11 @@  discard block
 block discarded – undo
138 138
     }
139 139
 }
140 140
 
141
-if (! function_exists('getCondition')) {
141
+if (!function_exists('getCondition')) {
142 142
     function getCondition($conditions)
143 143
     {
144 144
         $result = null;
145
-        if (! isset($conditions)) {
145
+        if (!isset($conditions)) {
146 146
             return false;
147 147
         }
148 148
 
Please login to merge, or discard this patch.
src/Services/CRUDGeneratorService.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -19,7 +19,7 @@  discard block
 block discarded – undo
19 19
     // Make Controller
20 20
     protected static function makeController($name, $console)
21 21
     {
22
-        if (! file_exists($path = app_path('/Http/Controllers/Admin'))) {
22
+        if (!file_exists($path = app_path('/Http/Controllers/Admin'))) {
23 23
             mkdir($path, 0777, true);
24 24
         }
25 25
         $controllerTemplate = str_replace(
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
     // Make Model
44 44
     protected static function makeModel($name, $console)
45 45
     {
46
-        if (! file_exists($path = app_path('/Models/Admin'))) {
46
+        if (!file_exists($path = app_path('/Models/Admin'))) {
47 47
             mkdir($path, 0777, true);
48 48
         }
49 49
         $modelTemplate = str_replace(
@@ -68,11 +68,11 @@  discard block
 block discarded – undo
68 68
     protected static function makeViews($name, $console)
69 69
     {
70 70
         $lowername = strtolower($name);
71
-        if (! file_exists($path = resource_path('views/admin/'.$lowername))) {
71
+        if (!file_exists($path = resource_path('views/admin/'.$lowername))) {
72 72
             mkdir($path, 0777, true);
73 73
         }
74 74
 
75
-        if (! file_exists($path = resource_path('views/admin/layouts/modules/'.$lowername))) {
75
+        if (!file_exists($path = resource_path('views/admin/layouts/modules/'.$lowername))) {
76 76
             mkdir($path, 0777, true);
77 77
         }
78 78
 
Please login to merge, or discard this patch.
src/Console/Commands/InstallAdmineticCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
     {
58 58
         $modelTemplate = file_get_contents(__DIR__.'/../../Console/Commands/AdminStubs/MyMenu.stub');
59 59
 
60
-        if (! file_exists($path = app_path('Services'))) {
60
+        if (!file_exists($path = app_path('Services'))) {
61 61
             mkdir($path, 0777, true);
62 62
         }
63 63
 
Please login to merge, or discard this patch.