@@ -163,6 +163,7 @@ public function recur(int $interval, string $job, array $data, ?string $queueNam
163163 public function pop ($ queueName = null )
164164 {
165165 $ connectionCount = $ this ->getClientCount ();
166+ $ job = null ;
166167
167168 for ($ i = 0 ; $ i < $ connectionCount ; $ i ++) {
168169 $ connection = $ this ->getNextConnection ();
@@ -198,7 +199,7 @@ public function pop($queueName = null)
198199 * @param string|null $queueName
199200 * @return bool
200201 */
201- public function subscribe (string $ topic , string $ queueName = null ): bool
202+ public function subscribe (string $ topic , ? string $ queueName = null ): bool
202203 {
203204 $ queueName = $ queueName ?? $ this ->defaultQueue ;
204205
@@ -217,7 +218,7 @@ public function subscribe(string $topic, string $queueName = null): bool
217218 * @param string|null $queueName
218219 * @return bool
219220 */
220- public function unSubscribe (string $ topic , string $ queueName = null ): bool
221+ public function unSubscribe (string $ topic , ? string $ queueName = null ): bool
221222 {
222223 $ queueName = $ queueName ?? $ this ->defaultQueue ;
223224
@@ -242,7 +243,7 @@ public function pushToTopic(string $topicName, string $job, array $data = [], ar
242243 {
243244 $ topic = new Topic ($ topicName , $ this ->getRandomConnection ());
244245
245- $ qlessOptions = $ payloadData [ ' data ' ] [self ::JOB_OPTIONS_KEY ] ?? [];
246+ $ qlessOptions = $ data [self ::JOB_OPTIONS_KEY ] ?? [];
246247 $ options = array_merge ($ qlessOptions , $ options );
247248
248249 return $ topic ->put (
0 commit comments