From 7a71d983545a3a18739f5b54b3d1b21354b41e3d Mon Sep 17 00:00:00 2001 From: ZGrguric Date: Sat, 3 Dec 2022 16:41:32 +0100 Subject: [PATCH] Pass cooldown callback to next() --- src/Api/AbstractMethod.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Api/AbstractMethod.php b/src/Api/AbstractMethod.php index a9fb9e7..0151599 100644 --- a/src/Api/AbstractMethod.php +++ b/src/Api/AbstractMethod.php @@ -248,6 +248,10 @@ public function next(): ?AbstractMethod $params['marker'] = $this->result->result->marker; $nextMethod = $this->client->api($this->method)->params($params); + if($this->cooldown_callback !== null) { + $nextMethod->setCooldownHandler($this->cooldown_callback); + } + return $nextMethod; }