From 566f5145a0172ad31a5ad0e7ef319f28438f63b0 Mon Sep 17 00:00:00 2001 From: Sebastian Lohff Date: Wed, 10 Jul 2019 00:04:46 +0200 Subject: [PATCH] Set client_id to None when none is specified --- mqtt_sensord/mqtt_sensord.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mqtt_sensord/mqtt_sensord.py b/mqtt_sensord/mqtt_sensord.py index 95e0bd1..ecfee5b 100755 --- a/mqtt_sensord/mqtt_sensord.py +++ b/mqtt_sensord/mqtt_sensord.py @@ -19,7 +19,7 @@ def main(): if 'client_id' in config['mqtt']: client_id = config['mqtt']['client_id'] else: - client_id = config['host']['name'] + client_id = None mqtt = MQTTClient(mcfg['host'], mcfg['user'], mcfg['password'], client_id) mqtt_topic = mcfg['sensor_topic']