Passed
Pull Request — master (#630)
by Daniel
17:21
created
app/Http/Controllers/Microblog/VoteController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
 
89 89
         return [
90 90
             'count' => $collection->count(),
91
-            'users' => $collection->when($collection->count() > 10, fn ($collection) => $collection->splice(0, 10)->concat(['...']))
91
+            'users' => $collection->when($collection->count() > 10, fn($collection) => $collection->splice(0, 10)->concat(['...']))
92 92
         ];
93 93
     }
94 94
 }
Please login to merge, or discard this patch.
app/Http/Controllers/Forum/BaseController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
             return $next($request);
63 63
         });
64 64
 
65
-        TagResource::urlResolver(fn ($name) => route('forum.tag', [urlencode($name)]));
65
+        TagResource::urlResolver(fn($name) => route('forum.tag', [urlencode($name)]));
66 66
     }
67 67
 
68 68
     /**
Please login to merge, or discard this patch.
app/Http/Controllers/Api/TopicsController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
      */
44 44
     public function __construct(Auth $auth, TopicRepository $repository)
45 45
     {
46
-        TagResource::urlResolver(fn ($name) => route('forum.tag', [urlencode($name)]));
46
+        TagResource::urlResolver(fn($name) => route('forum.tag', [urlencode($name)]));
47 47
 
48 48
         $this->repository = $repository;
49 49
         $this->user = $auth->guard('api')->user();
Please login to merge, or discard this patch.
app/Http/Resources/TagResource.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
         parent::__construct($resource);
25 25
 
26 26
         if (empty(static::$urlResolver)) {
27
-            static::$urlResolver = fn ($name) => route('job.tag', [urlencode($name)]);
27
+            static::$urlResolver = fn($name) => route('job.tag', [urlencode($name)]);
28 28
         }
29 29
     }
30 30
 
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
                 return $this->pivot->priority;
55 55
             }),
56 56
 
57
-            'category'  => $this->whenLoaded('category', fn () => $this->category->name)
57
+            'category'  => $this->whenLoaded('category', fn() => $this->category->name)
58 58
         ]);
59 59
     }
60 60
 }
Please login to merge, or discard this patch.
app/Http/Resources/UserResource.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
         $parent = $this->resource->only(['id', 'name', 'is_online', 'bio', 'location', 'allow_sig', 'allow_count', 'allow_smilies', 'posts', 'location', 'visited_at', 'created_at', 'group_name']);
25 25
 
26 26
         $result = array_merge(
27
-            array_filter($parent, fn ($value) => $value !== null),
27
+            array_filter($parent, fn($value) => $value !== null),
28 28
             [
29 29
                 'photo' => (string) $this->photo->url() ?: null,
30 30
                 'deleted_at' => $this->resource->deleted_at,
Please login to merge, or discard this patch.
app/Http/Resources/Api/MicroblogResource.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
                 'user'          => UserResource::make($this->user),
60 60
 
61 61
                 'permissions'   => [
62
-                    'update'    => $this->when($request->user(), fn () => $request->user()->can('update', $this->resource), false)
62
+                    'update'    => $this->when($request->user(), fn() => $request->user()->can('update', $this->resource), false)
63 63
                 ],
64 64
 
65 65
                 'comments_count'=> $this->when($this->comments_count, $this->comments_count),
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
                 }),
70 70
 
71 71
                 // @todo do zmiany na assets
72
-                'media'         => $this->whenLoaded('assets', fn () => AssetsResource::collection($this->assets), [])
72
+                'media'         => $this->whenLoaded('assets', fn() => AssetsResource::collection($this->assets), [])
73 73
             ]
74 74
         );
75 75
     }
@@ -83,6 +83,6 @@  discard block
 block discarded – undo
83 83
 
84 84
     private function isNotComment(): bool
85 85
     {
86
-        return ! $this->parent_id && $this->resource->relationLoaded('comments');
86
+        return !$this->parent_id && $this->resource->relationLoaded('comments');
87 87
     }
88 88
 }
Please login to merge, or discard this patch.
app/Http/Resources/Elasticsearch/JobResource.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -90,7 +90,7 @@
 block discarded – undo
90 90
             'suggest'           => $this->getSuggest(),
91 91
             'subscribers'       => $this->subscribers()->pluck('user_id'),
92 92
 
93
-            'firm'              => $this->when($this->firm_id, fn () => new FirmResource($this->firm))
93
+            'firm'              => $this->when($this->firm_id, fn() => new FirmResource($this->firm))
94 94
         ]);
95 95
 
96 96
         return $body;
Please login to merge, or discard this patch.
app/Http/Controllers/AssetsController.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -111,7 +111,7 @@
 block discarded – undo
111 111
         ];
112 112
 
113 113
         if (!$asset->isImage()) {
114
-            $headers['Content-Disposition'] = 'attachment; filename="'. $asset->name .'"';
114
+            $headers['Content-Disposition'] = 'attachment; filename="' . $asset->name . '"';
115 115
         }
116 116
 
117 117
         return response()->make($filesystem->get($asset->path), 200, $headers);
Please login to merge, or discard this patch.
app/Http/Requests/Forum/PostRequest.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -119,7 +119,7 @@
 block discarded – undo
119 119
 
120 120
     public function withValidator(Validator $validator)
121 121
     {
122
-        $shouldValidatePoll = fn () => count(array_filter($this->input('poll.items.*.text', []))) >= 1;
122
+        $shouldValidatePoll = fn() => count(array_filter($this->input('poll.items.*.text', []))) >= 1;
123 123
 
124 124
         $validator->sometimes('poll.items', ['min:2'], $shouldValidatePoll);
125 125
         $validator->sometimes('poll.items.*.text', ['required', 'string', 'max:200'], $shouldValidatePoll);
Please login to merge, or discard this patch.