fix an issue where the isemaildomain flag for a main-domain can be set to false when edited by customer

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann
2018-12-08 12:46:17 +01:00
parent ddddbdfb18
commit db36d57683
3 changed files with 8 additions and 6 deletions

View File

@@ -23,7 +23,9 @@ if ($action == '') {
$action = 'login';
}
if (session_status() == PHP_SESSION_NONE) {
session_start();
}
if ($action == '2fa_entercode') {
// page for entering the 2FA code after successful login

View File

@@ -521,7 +521,7 @@ class SubDomains extends ApiCommand implements ResourceEntity
// if allowed, check for 'is email domain'-flag
if ($result['parentdomainid'] != '0' && ($result['subcanemaildomain'] == '1' || $result['subcanemaildomain'] == '2') && $isemaildomain != $result['isemaildomain']) {
$isemaildomain = intval($isemaildomain);
} else {
} elseif ($result['parentdomainid'] != '0') {
$isemaildomain = $result['subcanemaildomain'] == '3' ? 1 : 0;
}