Update Docker/src/python/tHome/broker/connect.py
All checks were successful
Build and publish Image / build-and-push (push) Successful in 15s

This commit is contained in:
2024-03-06 23:54:04 +00:00
parent 54c2e5af98
commit b6f5ecda3b

View File

@@ -7,11 +7,11 @@ from . import config
import paho.mqtt.client as mqtt import paho.mqtt.client as mqtt
#=========================================================================== #===========================================================================
class Client( mqtt.Client(mqtt.CallbackAPIVersion.VERSION1) ): class Client( mqtt.Client ):
"""Logging client """Logging client
""" """
def __init__( self, log=None ): def __init__( self, log=None ):
mqtt.Client.__init__( self ) mqtt.Client.__init__( self, mqtt.CallbackAPIVersion.VERSION2 )
self._logger = log self._logger = log
# Restore callbacks overwritten by stupid mqtt library # Restore callbacks overwritten by stupid mqtt library
self.on_log = Client.on_log self.on_log = Client.on_log