This commit is contained in:
xyj 2023-12-07 19:05:43 +08:00
parent 8b4d7653ca
commit c02e314338
2 changed files with 1 additions and 6 deletions

View File

@ -23,9 +23,7 @@ def valid(msg, client):
if 'device_name' not in origin_data:
client.publish('error', payload='device_name must be supplied', qos=0)
return False
client.publish('error', payload=origin_data['device_name'], qos=0)
client.publish('error', payload=device_name, qos=0)
if origin_data['device_name'] != 'test':
if origin_data['device_name'] != device_name:
return False
return True

View File

@ -1,3 +0,0 @@
import os
print('test' == os.getenv('device_name'))