File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
src/FintechFab/LaravelQueueRabbitMQ/Queue Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 66use AMQPException ;
77use AMQPExchange ;
88use AMQPQueue ;
9+ use DateTime ;
910use FintechFab \LaravelQueueRabbitMQ \Queue \Jobs \RabbitMQJob ;
1011use Illuminate \Queue \Queue ;
1112use Illuminate \Queue \QueueInterface ;
@@ -198,15 +199,16 @@ public function declareQueue($name)
198199 }
199200
200201 /**
201- * @param string $destination
202+ * @param string $destination
202203 *
203- * @param int $delay
204+ * @param DateTime| int $delay
204205 *
205206 * @return AMQPQueue
206207 */
207208 public function declareDelayedQueue ($ destination , $ delay )
208209 {
209210 $ destination = $ this ->getQueueName ($ destination );
211+ $ delay = $ this ->getSeconds ($ delay );
210212 $ name = $ destination . '_deferred_ ' . $ delay ;
211213
212214 $ queue = new AMQPQueue ($ this ->channel );
You can’t perform that action at this time.
0 commit comments