Skip to content

Commit a92158a

Browse files
Update Lib/asyncio/base_events.py
Co-authored-by: Peter Bierma <[email protected]>
1 parent 8e409b7 commit a92158a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Lib/asyncio/base_events.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ def sockets(self):
366366
return tuple(trsock.TransportSocket(s) for s in self._sockets)
367367

368368
def close(self):
369-
if self._state == _ServerState.CLOSED or self._state == _ServerState.SHUTDOWN:
369+
if self._state in {_ServerState.CLOSED, _ServerState.SHUTDOWN}:
370370
return
371371
else:
372372
self._state = _ServerState.CLOSED

0 commit comments

Comments
 (0)