We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ -85,32 +85,32 @@ discard block |
||
85 | 85 | |
86 | 86 | $this->registerBackpackErrorViews(); |
87 | 87 | |
88 | - $this->app->bind('crud', function ($app) { |
|
88 | + $this->app->bind('crud', function($app) { |
|
89 | 89 | return CrudManager::identifyCrudPanel(); |
90 | 90 | }); |
91 | 91 | |
92 | - $this->app->scoped('CrudManager', function ($app) { |
|
92 | + $this->app->scoped('CrudManager', function($app) { |
|
93 | 93 | return new CrudPanelManager(); |
94 | 94 | }); |
95 | 95 | |
96 | - $this->app->scoped('DatabaseSchema', function ($app) { |
|
96 | + $this->app->scoped('DatabaseSchema', function($app) { |
|
97 | 97 | return new DatabaseSchema(); |
98 | 98 | }); |
99 | 99 | |
100 | - $this->app->scoped('BackpackLifecycleHooks', function ($app) { |
|
100 | + $this->app->scoped('BackpackLifecycleHooks', function($app) { |
|
101 | 101 | return new app\Library\CrudPanel\Hooks\LifecycleHooks(); |
102 | 102 | }); |
103 | 103 | |
104 | - $this->app->singleton('BackpackViewNamespaces', function ($app) { |
|
104 | + $this->app->singleton('BackpackViewNamespaces', function($app) { |
|
105 | 105 | return new ViewNamespaces(); |
106 | 106 | }); |
107 | 107 | |
108 | 108 | // Bind the widgets collection object to Laravel's service container |
109 | - $this->app->singleton('widgets', function ($app) { |
|
109 | + $this->app->singleton('widgets', function($app) { |
|
110 | 110 | return new Collection(); |
111 | 111 | }); |
112 | 112 | |
113 | - $this->app->scoped('UploadersRepository', function ($app) { |
|
113 | + $this->app->scoped('UploadersRepository', function($app) { |
|
114 | 114 | return new UploadersRepository(); |
115 | 115 | }); |
116 | 116 | |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | $middleware_key = config('backpack.base.middleware_key'); |
127 | 127 | $middleware_class = config('backpack.base.middleware_class'); |
128 | 128 | |
129 | - if (! is_array($middleware_class)) { |
|
129 | + if (!is_array($middleware_class)) { |
|
130 | 130 | $router->pushMiddlewareToGroup($middleware_key, $middleware_class); |
131 | 131 | |
132 | 132 | return; |
@@ -241,7 +241,7 @@ discard block |
||
241 | 241 | $configs = scandir(__DIR__."/config/backpack/$dir/"); |
242 | 242 | $configs = array_diff($configs, ['.', '..']); |
243 | 243 | |
244 | - if (! count($configs)) { |
|
244 | + if (!count($configs)) { |
|
245 | 245 | return; |
246 | 246 | } |
247 | 247 | |
@@ -290,8 +290,7 @@ discard block |
||
290 | 290 | // add the backpack_users password broker to the configuration |
291 | 291 | $laravelAuthPasswordBrokers = app()->config['auth.passwords']; |
292 | 292 | $laravelFirstPasswordBroker = is_array($laravelAuthPasswordBrokers) && current($laravelAuthPasswordBrokers) ? |
293 | - current($laravelAuthPasswordBrokers)['table'] : |
|
294 | - ''; |
|
293 | + current($laravelAuthPasswordBrokers)['table'] : ''; |
|
295 | 294 | |
296 | 295 | $backpackPasswordBrokerTable = config('backpack.base.password_resets_table') ?? |
297 | 296 | config('auth.passwords.users.table') ?? |
@@ -319,7 +318,7 @@ discard block |
||
319 | 318 | |
320 | 319 | public function loadViewComponents() |
321 | 320 | { |
322 | - $this->app->afterResolving(BladeCompiler::class, function () { |
|
321 | + $this->app->afterResolving(BladeCompiler::class, function() { |
|
323 | 322 | Blade::componentNamespace('Backpack\\CRUD\\app\\View\\Components', 'backpack'); |
324 | 323 | }); |
325 | 324 | } |
@@ -332,10 +331,10 @@ discard block |
||
332 | 331 | */ |
333 | 332 | private function registerDynamicBladeComponents() |
334 | 333 | { |
335 | - $path = __DIR__ . '/app/View/Components'; |
|
334 | + $path = __DIR__.'/app/View/Components'; |
|
336 | 335 | $namespace = 'Backpack\\CRUD\\app\\View\\Components'; |
337 | 336 | |
338 | - if (! is_dir($path)) { |
|
337 | + if (!is_dir($path)) { |
|
339 | 338 | return; |
340 | 339 | } |
341 | 340 | |
@@ -343,10 +342,10 @@ discard block |
||
343 | 342 | $relativePath = str_replace( |
344 | 343 | ['/', '.php'], |
345 | 344 | ['\\', ''], |
346 | - Str::after($file->getRealPath(), realpath($path) . DIRECTORY_SEPARATOR) |
|
345 | + Str::after($file->getRealPath(), realpath($path).DIRECTORY_SEPARATOR) |
|
347 | 346 | ); |
348 | 347 | |
349 | - $class = $namespace . '\\' . $relativePath; |
|
348 | + $class = $namespace.'\\'.$relativePath; |
|
350 | 349 | |
351 | 350 | // Check if the class exists and is a subclass of Illuminate\View\Component |
352 | 351 | // This ensures that only valid Blade components are registered. |
@@ -377,13 +376,13 @@ discard block |
||
377 | 376 | private function registerBackpackErrorViews() |
378 | 377 | { |
379 | 378 | // register the backpack error when the exception handler is resolved from the container |
380 | - $this->callAfterResolving(ExceptionHandler::class, function ($handler) { |
|
381 | - if (! Str::startsWith(request()->path(), config('backpack.base.route_prefix'))) { |
|
379 | + $this->callAfterResolving(ExceptionHandler::class, function($handler) { |
|
380 | + if (!Str::startsWith(request()->path(), config('backpack.base.route_prefix'))) { |
|
382 | 381 | return; |
383 | 382 | } |
384 | 383 | |
385 | 384 | // parse the namespaces set in config |
386 | - [$themeNamespace, $themeFallbackNamespace] = (function () { |
|
385 | + [$themeNamespace, $themeFallbackNamespace] = (function() { |
|
387 | 386 | $themeNamespace = config('backpack.ui.view_namespace'); |
388 | 387 | $themeFallbackNamespace = config('backpack.ui.view_namespace_fallback'); |
389 | 388 | |
@@ -400,8 +399,7 @@ discard block |
||
400 | 399 | // - fallback theme paths |
401 | 400 | // - ui path |
402 | 401 | $themeErrorPaths = $viewFinderHints[$themeNamespace] ?? []; |
403 | - $themeErrorPaths = $themeNamespace === $themeFallbackNamespace ? $themeErrorPaths : |
|
404 | - array_merge($viewFinderHints[$themeFallbackNamespace] ?? [], $themeErrorPaths); |
|
402 | + $themeErrorPaths = $themeNamespace === $themeFallbackNamespace ? $themeErrorPaths : array_merge($viewFinderHints[$themeFallbackNamespace] ?? [], $themeErrorPaths); |
|
405 | 403 | $uiErrorPaths = [base_path('vendor/backpack/crud/src/resources/views/ui')]; |
406 | 404 | $themeErrorPaths = array_merge($themeErrorPaths, $uiErrorPaths); |
407 | 405 |