mirror of
https://github.com/postfixadmin/postfixadmin.git
synced 2024-09-19 11:12:15 +02:00
code formatting fix
This commit is contained in:
parent
85e92f4012
commit
45557a6ed4
@ -308,15 +308,16 @@ function check_domain($domain)
|
||||
* @param string $domain
|
||||
* @return string empty if the domain is valid, otherwise string with the errormessage
|
||||
*/
|
||||
function check_localaliasonly($domain) {
|
||||
function check_localaliasonly($domain)
|
||||
{
|
||||
// If emailcheck_localaliasonly is set to 'YES', disallow aliases to remote servers (but allow aliases on this server)
|
||||
if (Config::bool('emailcheck_localaliasonly')) {
|
||||
// get the domain part of the e-mail
|
||||
list(/*NULL*/, $domain) = explode('@', $domain);
|
||||
|
||||
|
||||
// get all domains managed on this system by postfixadmin
|
||||
$domains = list_domains();
|
||||
|
||||
|
||||
// Only allow local domains to be alias destinations
|
||||
if (in_array($domain, $domains)) {
|
||||
return '';
|
||||
@ -325,9 +326,8 @@ function check_localaliasonly($domain) {
|
||||
return sprintf("You may only make aliases to domains hosted on this server. %s is a remote domain name.", htmlentities($domain));
|
||||
}
|
||||
} else {
|
||||
return '';
|
||||
return '';
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -30,7 +30,9 @@ $id = safeget('id');
|
||||
$table = safeget('table');
|
||||
$field = safeget('field');
|
||||
$active = safeget('active');
|
||||
if ($field === '') $field = 'active';
|
||||
if ($field === '') {
|
||||
$field = 'active';
|
||||
}
|
||||
|
||||
if (empty($table)) {
|
||||
die("Invalid table name given");
|
||||
|
@ -2350,6 +2350,7 @@ function upgrade_1849_sqlite()
|
||||
");
|
||||
}
|
||||
|
||||
function upgrade_1850() {
|
||||
function upgrade_1850()
|
||||
{
|
||||
_db_add_field('mailbox', 'smtp_active', 'int DEFAULT 1');
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user