Passed
Push — master ( d065eb...233263 )
by Reza
04:00
created
src/helpers.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,8 +1,8 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-if(! function_exists('getRouteName'))
3
+if (!function_exists('getRouteName'))
4 4
 {
5
-    function getRouteName(){
5
+    function getRouteName() {
6 6
         $routeName = config('easy_panel.route_prefix');
7 7
         $routeName = trim($routeName, '/');
8 8
         $routeName = str_replace('/', '.', $routeName);
@@ -10,9 +10,9 @@  discard block
 block discarded – undo
10 10
     }
11 11
 }
12 12
 
13
-if(! function_exists('get_icon'))
13
+if (!function_exists('get_icon'))
14 14
 {
15
-    function get_icon($type){
15
+    function get_icon($type) {
16 16
         $array = [
17 17
             'file-text' => ['posts', 'article', 'stories', 'post', 'articles', 'story'],
18 18
             'users' => ['users', 'user', 'accounts', 'account', 'admins', 'admin', 'employee', 'employees'],
@@ -25,8 +25,8 @@  discard block
 block discarded – undo
25 25
             'music' => ['musics', 'music', 'audios', 'audio'],
26 26
             'bell' => ['notifications', 'notification'],
27 27
         ];
28
-        foreach ($array as $key => $arrayValues){
29
-            if(in_array($type, $arrayValues)){
28
+        foreach ($array as $key => $arrayValues) {
29
+            if (in_array($type, $arrayValues)) {
30 30
                 $val = $key;
31 31
             }
32 32
         }
Please login to merge, or discard this patch.
src/EasyPanelServiceProvider.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -25,8 +25,8 @@  discard block
 block discarded – undo
25 25
 {
26 26
     public function register()
27 27
     {
28
-        $this->mergeConfigFrom(__DIR__ . '/../config/easy_panel_config.php', 'easy_panel');
29
-        if(!config('easy_panel.enable')) {
28
+        $this->mergeConfigFrom(__DIR__.'/../config/easy_panel_config.php', 'easy_panel');
29
+        if (!config('easy_panel.enable')) {
30 30
             return;
31 31
         }
32 32
 
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
         $this->bindCommands();
35 35
 
36 36
         foreach (config('easy_panel.actions') as $action) {
37
-            if(!File::exists(resource_path("cruds/$action.php"))) {
37
+            if (!File::exists(resource_path("cruds/$action.php"))) {
38 38
                 continue;
39 39
             }
40 40
             $data = require resource_path("cruds/$action.php");
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
 
46 46
     public function boot()
47 47
     {
48
-        if(!config('easy_panel.enable')) {
48
+        if (!config('easy_panel.enable')) {
49 49
             return;
50 50
         }
51 51
 
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
         }
55 55
 
56 56
         // Load Views
57
-        $this->loadViewsFrom(__DIR__ . '/../resources/views', 'admin');
57
+        $this->loadViewsFrom(__DIR__.'/../resources/views', 'admin');
58 58
 
59 59
         // Register Middleware
60 60
         $this->registerMiddlewareAlias();
@@ -68,11 +68,11 @@  discard block
 block discarded – undo
68 68
 
69 69
     private function defineRoutes()
70 70
     {
71
-        if(!$this->app->routesAreCached()) {
71
+        if (!$this->app->routesAreCached()) {
72 72
             Route::prefix(config('easy_panel.route_prefix'))
73 73
                 ->middleware(['web', 'auth', 'isAdmin'])
74
-                ->name(getRouteName() . '.')
75
-                ->group(__DIR__ . '/routes.php');
74
+                ->name(getRouteName().'.')
75
+                ->group(__DIR__.'/routes.php');
76 76
         }
77 77
     }
78 78
 
@@ -97,13 +97,13 @@  discard block
 block discarded – undo
97 97
 
98 98
     private function mergePublishes()
99 99
     {
100
-        $this->publishes([__DIR__ . '/../config/easy_panel_config.php' => config_path('easy_panel.php')], 'easy-panel-config');
100
+        $this->publishes([__DIR__.'/../config/easy_panel_config.php' => config_path('easy_panel.php')], 'easy-panel-config');
101 101
 
102
-        $this->publishes([__DIR__ . '/../resources/views' => resource_path('/views/vendor/admin')], 'easy-panel-views');
102
+        $this->publishes([__DIR__.'/../resources/views' => resource_path('/views/vendor/admin')], 'easy-panel-views');
103 103
 
104
-        $this->publishes([__DIR__ . '/../resources/assets' => public_path('/assets/vendor/admin'), __DIR__ . '/../resources/dist' => public_path('/dist/vendor/admin')], 'easy-panel-styles');
104
+        $this->publishes([__DIR__.'/../resources/assets' => public_path('/assets/vendor/admin'), __DIR__.'/../resources/dist' => public_path('/dist/vendor/admin')], 'easy-panel-styles');
105 105
 
106
-        $this->publishes([__DIR__ . '/../database/migrations/2020_09_05_99999_create_todos_table.php' => base_path('/database/migrations/' . date('Y_m_d') . '_99999_create_admin_todos_table.php')], 'easy-panel-migrations');
106
+        $this->publishes([__DIR__.'/../database/migrations/2020_09_05_99999_create_todos_table.php' => base_path('/database/migrations/'.date('Y_m_d').'_99999_create_admin_todos_table.php')], 'easy-panel-migrations');
107 107
 
108 108
         $this->publishes([__DIR__.'/../resources/cruds' => resource_path('/cruds')], 'easy-panel-cruds');
109 109
     }
Please login to merge, or discard this patch.