Skip to content

Commit

Permalink
Fix: support voltage of string and number
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinelliott committed Aug 21, 2024
1 parent 717f11c commit 1ea5bc0
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion templates/static/node.html.j2
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,11 @@
{% if node.telemetry.voltage %}
<span class="mr-4 align-middle" title="Voltage">
<img src="images/icons/voltage.svg" alt="Voltage" class="w-4 h-4 inline-block align-middle">
{{ node.telemetry.voltage | round(1) }}V
{% if node.telemetry.voltage is number %}
{{ node.telemetry.voltage | round(1) }}V
{% else %}
{{ node.telemetry.voltage }}
{% endif %}
</span>
{% endif %}
{% endif %}
Expand Down

0 comments on commit 1ea5bc0

Please sign in to comment.