Skip to content

Commit 5515c91

Browse files
committed
Correct typing for MQTT to be "MQTT.MQTT"
MQTT alone references the module as imported
1 parent 747b4cd commit 5515c91

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

adafruit_funhouse/network.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ def init_mqtt(
9191
username: str = None,
9292
password: str = None,
9393
use_io: bool = False,
94-
) -> Union[MQTT, IO_MQTT]:
94+
) -> Union[MQTT.MQTT, IO_MQTT]:
9595
"""Initialize MQTT"""
9696
self.connect()
9797
self._mqtt_client = MQTT.MQTT(
@@ -109,7 +109,7 @@ def init_mqtt(
109109

110110
# pylint: enable=too-many-arguments
111111

112-
def _get_mqtt_client(self) -> Union[MQTT, IO_MQTT]:
112+
def _get_mqtt_client(self) -> Union[MQTT.MQTT, IO_MQTT]:
113113
if self._mqtt_client is not None:
114114
return self._mqtt_client
115115
raise RuntimeError("Please initialize MQTT before using")

0 commit comments

Comments
 (0)