From a043673ff0a84a9fc6b4bc9ccaddc143995b4789 Mon Sep 17 00:00:00 2001 From: JJTech0130 Date: Wed, 11 Oct 2023 18:03:41 -0400 Subject: [PATCH] bug: .pop() payload from incoming queue always --- apns.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apns.py b/apns.py index 8b69b48..4ee91fd 100644 --- a/apns.py +++ b/apns.py @@ -115,9 +115,9 @@ class APNSConnection: if payload.id == id: if filter is not None: if filter(payload): - return payload + return self._incoming_queue.pop() else: - return payload + return self._incoming_queue.pop() while True: await self._queue_park.wait() # Wait for a new payload to be added to the queue logger.debug(f"Woken by event, checking for {id}")