diff --git a/src/main/kotlin/MQTTSubscriber.kt b/src/main/kotlin/MQTTSubscriber.kt index 8cda5d4..5eebd05 100644 --- a/src/main/kotlin/MQTTSubscriber.kt +++ b/src/main/kotlin/MQTTSubscriber.kt @@ -15,7 +15,7 @@ class MqttSubscriber() : MqttCallbackExtended { connOpts.userName = "birbnetes" connOpts.password = "de4d2182".toCharArray() connOpts.isAutomaticReconnect = true - mqttClient.setCallback(MqttSubscriber()) + mqttClient.setCallback(this) } override fun connectionLost(arg0: Throwable) {