From 5f81bc2cc9895b5db37225e94d23317903a91878 Mon Sep 17 00:00:00 2001 From: Russell Keith-Magee Date: Sat, 4 May 2024 12:40:15 +0800 Subject: [PATCH] Removed a Python 3.7 compatibility shim. --- src/gbulb/transports.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/gbulb/transports.py b/src/gbulb/transports.py index 1d31d78..ac5ee9b 100644 --- a/src/gbulb/transports.py +++ b/src/gbulb/transports.py @@ -105,8 +105,7 @@ def __init__(self, *args, **kwargs): self._loop.call_soon(self._loop_reading) def set_protocol(self, protocol): - if hasattr(asyncio, "BufferedProtocol"): # Python 3.7+ - self._alloc_read_buffers = isinstance(protocol, asyncio.BufferedProtocol) + self._alloc_read_buffers = isinstance(protocol, asyncio.BufferedProtocol) super().set_protocol(protocol) def pause_reading(self):