Allow effect values at 0.1 precision

This commit is contained in:
Jage9
2026-02-21 03:10:53 -05:00
parent f52cc04f26
commit dd48c01601
4 changed files with 6 additions and 6 deletions

View File

@@ -654,7 +654,7 @@ class SignalingServer:
next_params["channel"] = channel
try:
effect_value = int(next_params.get("effectValue", 50))
effect_value = float(next_params.get("effectValue", 50))
except (TypeError, ValueError):
await self._send_item_result(client, False, "update", "effectValue must be a number.", item.id)
return
@@ -663,7 +663,7 @@ class SignalingServer:
client, False, "update", "effectValue must be between 0 and 100.", item.id
)
return
next_params["effectValue"] = round(effect_value / 5) * 5
next_params["effectValue"] = round(effect_value, 1)
item.params = next_params
item.updatedAt = self.item_service.now_ms()
item.version += 1