diff options
Diffstat (limited to 'userprefs.cgi')
-rwxr-xr-x | userprefs.cgi | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/userprefs.cgi b/userprefs.cgi index 92e110f3b..9c2135eb3 100755 --- a/userprefs.cgi +++ b/userprefs.cgi @@ -232,7 +232,9 @@ sub SaveEmail { foreach my $rel (RELATIONSHIPS) { # Positive events: a ticked box means "send me mail." foreach my $event (POS_EVENTS) { - if (1 == $cgi->param("email-$rel-$event")) { + if (defined($cgi->param("email-$rel-$event")) + && $cgi->param("email-$rel-$event") == 1) + { $dbh->do("INSERT INTO email_setting " . "(user_id, relationship, event) " . "VALUES ($userid, $rel, $event)"); |