You've already forked postfixadmin
mirror of
https://github.com/postfixadmin/postfixadmin.git
synced 2026-01-12 22:51:27 +03:00
adjust pgsql $row['v_active'] only if vacation is enabled
This avoids an "Undefined index" warning if vacation is disabled. Fixes: https://github.com/postfixadmin/postfixadmin/issues/118
This commit is contained in:
@@ -243,10 +243,13 @@ if ($result['rows'] > 0) {
|
||||
$row['modified'] = date('Y-m-d H:i', strtotime($row['modified']));
|
||||
$row['created'] = date('Y-m-d H:i', strtotime($row['created']));
|
||||
$row['active']=('t'==$row['active']) ? 1 : 0;
|
||||
if($row['v_active'] == NULL) {
|
||||
$row['v_active'] = 'f';
|
||||
|
||||
if (Config::bool('vacation_control_admin')) {
|
||||
if($row['v_active'] == NULL) {
|
||||
$row['v_active'] = 'f';
|
||||
}
|
||||
$row['v_active']=('t'==$row['v_active']) ? 1 : 0;
|
||||
}
|
||||
$row['v_active']=('t'==$row['v_active']) ? 1 : 0;
|
||||
}
|
||||
$tMailbox[] = $row;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user