From: Michael Tremer Date: Sat, 29 Apr 2023 13:06:20 +0000 (+0000) Subject: users: Fix rending page when users have no quota X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=77077723abd49afe0bf75da43ffcb017ab083174;p=pbs.git users: Fix rending page when users have no quota Signed-off-by: Michael Tremer --- diff --git a/src/templates/users/show.html b/src/templates/users/show.html index 26014fad..c1c5c992 100644 --- a/src/templates/users/show.html +++ b/src/templates/users/show.html @@ -46,10 +46,17 @@
-

{{ _("Disk Quota") }}

-

- {{ format_size(user.disk_usage) }}/{{ format_size(user.quota) }} -

+ {% if user.quota %} +

{{ _("Disk Quota") }}

+

+ {{ format_size(user.disk_usage) }}/{{ format_size(user.quota) }} +

+ {% else %} +

{{ _("Disk Usage") }}

+

+ {{ format_size(user.disk_usage) }} +

+ {% end %}