check quota_multiplier is numeric, else set it to 1; see: https://github.com/postfixadmin/postfixadmin/issues/65 - backport patch from master (not a clean cherry-pick)

postfixadmin_3.2
David Goodwin 6 years ago
parent c65a99ce2d
commit 52e639f1fc

@ -217,7 +217,10 @@ class MailboxHandler extends PFAHandler {
protected function beforestore() {
if (isset($this->values['quota']) && $this->values['quota'] != -1) {
$this->values['quota'] = $this->values['quota'] * Config::read('quota_multiplier'); # convert quota from MB to bytes
if ($multiplier == 0 || !is_numeric($multiplier)) { // or empty string, or null, or false...
$multiplier = 1;
}
$this->values['quota'] = $this->values['quota'] * $multiplier; # convert quota from MB to bytes
}
$ah = new AliasHandler($this->new, $this->admin_username);

Loading…
Cancel
Save