@@ -61,7 +61,7 @@ discard block |
||
61 | 61 | $path_parts = pathinfo($path); |
62 | 62 | } |
63 | 63 | |
64 | - return substr($path_parts[$part_name], 1); |
|
64 | + return substr($path_parts[ $part_name ], 1); |
|
65 | 65 | } |
66 | 66 | |
67 | 67 | public function allowFolderType($type) |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | $lfm_type = 'file'; |
91 | 91 | |
92 | 92 | $request_type = lcfirst(Str::singular($this->input('type') ?: '')); |
93 | - $available_types = array_keys($this->config->get('lfm.folder_categories') ?: []); |
|
93 | + $available_types = array_keys($this->config->get('lfm.folder_categories') ?: [ ]); |
|
94 | 94 | |
95 | 95 | if (in_array($request_type, $available_types)) { |
96 | 96 | $lfm_type = $request_type; |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | $view_type = 'grid'; |
108 | 108 | $target_display_type = $this->input('show_list') ?: $startup_view; |
109 | 109 | |
110 | - if (in_array($target_display_type, ['list', 'grid'])) { |
|
110 | + if (in_array($target_display_type, [ 'list', 'grid' ])) { |
|
111 | 111 | $view_type = $target_display_type; |
112 | 112 | } |
113 | 113 | |
@@ -191,7 +191,7 @@ discard block |
||
191 | 191 | */ |
192 | 192 | public function allowShareFolder() |
193 | 193 | { |
194 | - if (! $this->allowMultiUser()) { |
|
194 | + if (!$this->allowMultiUser()) { |
|
195 | 195 | return true; |
196 | 196 | } |
197 | 197 | |
@@ -206,14 +206,14 @@ discard block |
||
206 | 206 | */ |
207 | 207 | public function translateFromUtf8($input) |
208 | 208 | { |
209 | - $rInput = []; |
|
209 | + $rInput = [ ]; |
|
210 | 210 | |
211 | 211 | if ($this->isRunningOnWindows()) { |
212 | 212 | // $input = iconv('UTF-8', mb_detect_encoding($input), $input); |
213 | 213 | |
214 | 214 | if (is_array($input)) { |
215 | 215 | foreach ($input as $k => $i) { |
216 | - $rInput[] = iconv('UTF-8', mb_detect_encoding($i), $i); |
|
216 | + $rInput[ ] = iconv('UTF-8', mb_detect_encoding($i), $i); |
|
217 | 217 | } |
218 | 218 | } else { |
219 | 219 | $rInput = $input; |
@@ -258,7 +258,7 @@ discard block |
||
258 | 258 | * @param mixed $variables Variables the message needs. |
259 | 259 | * @return string |
260 | 260 | */ |
261 | - public function error($error_type, $variables = []) |
|
261 | + public function error($error_type, $variables = [ ]) |
|
262 | 262 | { |
263 | 263 | throw new \Exception(trans(self::PACKAGE_NAME . '::lfm.error-' . $error_type, $variables)); |
264 | 264 | } |
@@ -274,7 +274,7 @@ discard block |
||
274 | 274 | $as = 'unisharp.lfm.'; |
275 | 275 | $namespace = '\\UniSharp\\LaravelFilemanager\\Controllers\\'; |
276 | 276 | |
277 | - Route::group(compact('middleware', 'as', 'namespace'), function () { |
|
277 | + Route::group(compact('middleware', 'as', 'namespace'), function() { |
|
278 | 278 | |
279 | 279 | // display main layout |
280 | 280 | Route::get('/', [ |