Skip to content

Commit

Permalink
FIx padding
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul.Cavill authored and Paul.Cavill committed Oct 11, 2023
1 parent 5809949 commit 279b17d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion custom_components/localtuya/cloud_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ async def async_get_devices_list(self):

return "ok"

async def async_get_device_specifications(self, device_id):
async def async_get_device_specifications(self, device_id):
"""Obtain the DP ID mappings for a device."""
resp = await self.async_make_request(
"GET", url=f"/v1.1/devices/{device_id}/specifications"
Expand All @@ -148,6 +148,8 @@ async def async_get_device_specifications(self, device_id):
return {}, "Request failed, status " + str(resp.status)

r_json = resp.json()
_LOGGER.debug("SPECS resp: %s", r_json)

if not r_json["success"]:
return {}, f"Error {r_json['code']}: {r_json['msg']}"

Expand Down

0 comments on commit 279b17d

Please sign in to comment.