Просмотр исходного кода

fix (infrared): dump json into string for sending

Jason Rumney 3 месяцев назад
Родитель
Сommit
fd3aa3bf6c
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      custom_components/tuya_local/infrared.py

+ 1 - 1
custom_components/tuya_local/infrared.py

@@ -97,7 +97,7 @@ class TuyaLocalInfrared(TuyaLocalEntity, InfraredEntity):
             "head": "",
             "key1": "1" + command,
         }
-        return json_command
+        return json.dumps(json_command)
 
     def _package_multi_dp_send(self, command: str) -> dict:
         """Package the command for a multi DP send"""