We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ -19,8 +19,8 @@ discard block |
||
19 | 19 | * - when true: `address[street]` |
20 | 20 | * - when false: `[address][street]` |
21 | 21 | */ |
22 | -if (! Str::hasMacro('dotsToSquareBrackets')) { |
|
23 | - Str::macro('dotsToSquareBrackets', function ($string, $ignore = [], $keyFirst = true) { |
|
22 | +if (!Str::hasMacro('dotsToSquareBrackets')) { |
|
23 | + Str::macro('dotsToSquareBrackets', function($string, $ignore = [], $keyFirst = true) { |
|
24 | 24 | $stringParts = explode('.', $string); |
25 | 25 | $result = ''; |
26 | 26 | |
@@ -34,8 +34,8 @@ discard block |
||
34 | 34 | return $result; |
35 | 35 | }); |
36 | 36 | } |
37 | -if (! CrudColumn::hasMacro('withFiles')) { |
|
38 | - CrudColumn::macro('withFiles', function ($uploadDefinition = [], $subfield = null, $registerUploaderEvents = true) { |
|
37 | +if (!CrudColumn::hasMacro('withFiles')) { |
|
38 | + CrudColumn::macro('withFiles', function($uploadDefinition = [], $subfield = null, $registerUploaderEvents = true) { |
|
39 | 39 | /** @var CrudField|CrudColumn $this */ |
40 | 40 | RegisterUploadEvents::handle($this, $uploadDefinition, 'withFiles', $subfield, $registerUploaderEvents); |
41 | 41 | |
@@ -43,8 +43,8 @@ discard block |
||
43 | 43 | }); |
44 | 44 | } |
45 | 45 | |
46 | -if (! CrudField::hasMacro('withFiles')) { |
|
47 | - CrudField::macro('withFiles', function ($uploadDefinition = [], $subfield = null, $registerUploaderEvents = true) { |
|
46 | +if (!CrudField::hasMacro('withFiles')) { |
|
47 | + CrudField::macro('withFiles', function($uploadDefinition = [], $subfield = null, $registerUploaderEvents = true) { |
|
48 | 48 | /** @var CrudField|CrudColumn $this */ |
49 | 49 | RegisterUploadEvents::handle($this, $uploadDefinition, 'withFiles', $subfield, $registerUploaderEvents); |
50 | 50 | |
@@ -52,8 +52,8 @@ discard block |
||
52 | 52 | }); |
53 | 53 | } |
54 | 54 | |
55 | -if (! CrudColumn::hasMacro('linkTo')) { |
|
56 | - CrudColumn::macro('linkTo', function (string|array $routeNameOrConfiguration, ?string $target = null): static { |
|
55 | +if (!CrudColumn::hasMacro('linkTo')) { |
|
56 | + CrudColumn::macro('linkTo', function(string | array $routeNameOrConfiguration, ?string $target = null): static { |
|
57 | 57 | if (is_array($routeNameOrConfiguration)) { |
58 | 58 | $routeName = $routeNameOrConfiguration['routeName'] ?? null; |
59 | 59 | $target = $routeNameOrConfiguration['target'] ?? $target; |
@@ -63,7 +63,7 @@ discard block |
||
63 | 63 | |
64 | 64 | $route = Route::getRoutes()->getByName($routeName); |
65 | 65 | |
66 | - if (! $route) { |
|
66 | + if (!$route) { |
|
67 | 67 | throw new \Exception("Route [{$routeName}] not found while building the link for column [{$this->name}]."); |
68 | 68 | } |
69 | 69 | |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | if (count($parameters) === 1) { |
81 | 81 | $entity = $crud->isAttributeInRelationString($column) ? Str::before($column['entity'], '.') : $column['entity']; |
82 | 82 | $parameterValue = $related_key ?? $entry->{$entity}?->getKey(); |
83 | - if (! $parameterValue) { |
|
83 | + if (!$parameterValue) { |
|
84 | 84 | return null; |
85 | 85 | } |
86 | 86 | return route($routeName, [$parameters[0] => $parameterValue]); |
@@ -98,8 +98,8 @@ discard block |
||
98 | 98 | * |
99 | 99 | * It will go to the given CrudController and get the setupRoutes() method on it. |
100 | 100 | */ |
101 | -if (! Route::hasMacro('crud')) { |
|
102 | - Route::macro('crud', function ($name, $controller) { |
|
101 | +if (!Route::hasMacro('crud')) { |
|
102 | + Route::macro('crud', function($name, $controller) { |
|
103 | 103 | // put together the route name prefix, |
104 | 104 | // as passed to the Route::group() statements |
105 | 105 | $routeName = ''; |