File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -118,12 +118,12 @@ public function stop(): void
118118 $ this ->send ('' , $ this ->encode (['stop ' => true ]));
119119 }
120120
121- public function hasPayload (string $ class = null ): bool
121+ public function hasPayload (? string $ class = null ): bool
122122 {
123123 return $ this ->findPayload ($ class ) !== null ;
124124 }
125125
126- public function getPayload (string $ class = null ): ?Payload
126+ public function getPayload (? string $ class = null ): ?Payload
127127 {
128128 $ pos = $ this ->findPayload ($ class );
129129 if ($ pos === null ) {
@@ -140,7 +140,7 @@ public function getPayload(string $class = null): ?Payload
140140 *
141141 * @return null|int Index in {@see $this->payloads} or null if not found
142142 */
143- private function findPayload (string $ class = null ): ?int
143+ private function findPayload (? string $ class = null ): ?int
144144 {
145145 // Find in existing payloads
146146 if ($ this ->payloads !== []) {
Original file line number Diff line number Diff line change @@ -51,13 +51,13 @@ public function stop(): void;
5151 *
5252 * @return bool Returns {@see true} if worker is ready to accept new payload.
5353 */
54- public function hasPayload (string $ class = null ): bool ;
54+ public function hasPayload (? string $ class = null ): bool ;
5555
5656 /**
5757 * @param class-string<Payload>|null $class
5858 *
5959 * @return Payload|null Returns {@see null} if worker is not ready to accept new payload and has no cached payload
6060 * of the given type.
6161 */
62- public function getPayload (string $ class = null ): ?Payload ;
62+ public function getPayload (? string $ class = null ): ?Payload ;
6363}
You can’t perform that action at this time.
0 commit comments