mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-09 18:45:54 +02:00
ipblocklist.cgi: Fix settings checkbox handling
Checkboxes does not submit any values if they are not checked. Default them to "off" in such a case. This fixes the issue not beeing able to disable the logging. Fixes #12979. Signed-off-by: Stefan Schantl <stefan.schantl@ipfire.org> Reviewed-by: Adolf Belka <adolf.belka@ipfire.org>
This commit is contained in:
committed by
Peter Müller
parent
1b70ead36d
commit
0450dce6f6
@@ -72,6 +72,10 @@ my @blocklists = &IPblocklist::get_blocklists();
|
||||
|
||||
# Process actions
|
||||
if ($cgiparams{'ACTION'} eq "$Lang::tr{'save'}") {
|
||||
# Assign checkbox values, in case they are not checked.
|
||||
$cgiparams{'ENABLE'} = "off" unless($cgiparams{'ENABLE'});
|
||||
$cgiparams{'LOGGING'} = "off" unless($cgiparams{'LOGGING'});
|
||||
|
||||
# Array to store if blocklists are missing on the system
|
||||
# and needs to be downloaded first.
|
||||
my @missing_blocklists = ();
|
||||
|
||||
Reference in New Issue
Block a user