From 65fa670da4dbe78a4f81205da4fa2640c603fa24 Mon Sep 17 00:00:00 2001 From: Ilia Rostovtsev Date: Mon, 27 Jan 2020 22:08:19 +0300 Subject: [PATCH] Create ability to by-pass usage of `theme_nice_size` (like in virtualmin-support) --- web-lib-funcs.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/web-lib-funcs.pl b/web-lib-funcs.pl index 8a880fce2..a317ef22a 100755 --- a/web-lib-funcs.pl +++ b/web-lib-funcs.pl @@ -8696,7 +8696,8 @@ my ($bytes, $minimal, $decimal) = @_; &load_theme_library(); if (defined(&theme_nice_size) && $main::header_content_type eq "text/html" && - $main::webmin_script_type eq "web") { + $main::webmin_script_type eq "web" && + !$main::theme_forbid_nice_size) { return &theme_nice_size($_[0], $_[1], $_[2]); } my ($decimal_units, $binary_units) = (1000, 1024);