Skip to content

Commit

Permalink
Fixing send_command
Browse files Browse the repository at this point in the history
  • Loading branch information
SeraphicRav committed Jul 10, 2024
1 parent c33163b commit 01c648d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "switchbot_api"
version = "2.2.0"
version = "2.2.1"
description = "An asynchronous library to use Switchbot API"
authors = ["Ravaka Razafimanantsoa <[email protected]>"]
license = "MIT"
Expand Down
2 changes: 1 addition & 1 deletion switchbot_api/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ async def send_command(
"""
json = {
"commandType": command_type,
"command": command if isinstance(command, Commands) else command,
"command": command.value if isinstance(command, Commands) else command,
"parameter": parameters,
}
await self._request(f"devices/{device_id}/commands", callback="post", json=json)

0 comments on commit 01c648d

Please sign in to comment.