Make it a string in accordance to the return value type

This commit is contained in:
Peter Pfeufer committed 2022-05-12 13:31:06 +02:00
1 parent 8dd07b97c7
commit 17b06c8845
1 file changed
+1 -1
+1 -1
View File
@@ -39,7 +39,7 @@ logger = logging.getLogger(__name__)
@register.simple_tag()
def decimal_widthratio(this_value, max_value, max_width) -> str:
if max_value == 0:
return 0
return str(0)
return str(round(this_value/max_value * max_width, 2))