Skip to content

Commit b8faf33

Browse files
committed
Minor fix in stop method, use correct property to check if the client is connected
1 parent 94a8831 commit b8faf33

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pymodbus/client/async/asyncio/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ def stop(self):
687687
Stops connection
688688
:return:
689689
"""
690-
if self._connected.is_set():
690+
if self._connected:
691691
if self.protocol:
692692
if self.protocol.transport:
693693
self.protocol.transport.close()

0 commit comments

Comments
 (0)