From f7c7e35b34cb8de3929058ff390d2c9531d335e2 Mon Sep 17 00:00:00 2001 From: David Goodwin Date: Sun, 15 Sep 2019 11:42:21 +0100 Subject: [PATCH] fix formatting --- functions.inc.php | 2 +- model/CliDelete.php | 2 +- model/CliEdit.php | 2 +- model/MailboxHandler.php | 2 +- scripts/postfixadmin-cli.php | 3 +-- 5 files changed, 5 insertions(+), 6 deletions(-) diff --git a/functions.inc.php b/functions.inc.php index 33d00a5f..bb2f75d2 100644 --- a/functions.inc.php +++ b/functions.inc.php @@ -1915,7 +1915,7 @@ function db_where_clause($condition, $struct, $additional_raw_where = '', $searc } elseif (!is_array($searchmode)) { throw new Exception('db_where_cond: parameter $searchmode is not an array!'); } elseif (count($condition) == 0 && trim($additional_raw_where) == '') { - throw new Exception("db_where_cond: parameter is an empty array!"); + throw new Exception("db_where_cond: parameter is an empty array!"); } elseif (!is_array($struct)) { throw new Exception('db_where_cond: parameter $struct is not an array!'); } diff --git a/model/CliDelete.php b/model/CliDelete.php index 7de6251c..f032f3aa 100644 --- a/model/CliDelete.php +++ b/model/CliDelete.php @@ -53,7 +53,7 @@ class CliDelete extends Shell { if (!$handler->delete()) { $this->err($handler->errormsg); return 1; - } + } $this->out($handler->infomsg); return 0; } diff --git a/model/CliEdit.php b/model/CliEdit.php index a86acbb9..f39bba1d 100644 --- a/model/CliEdit.php +++ b/model/CliEdit.php @@ -189,7 +189,7 @@ class CliEdit extends Shell { if (!$handler->store()) { $this->err($handler->errormsg); return 1; - } + } $this->out(""); $this->out($handler->infomsg); diff --git a/model/MailboxHandler.php b/model/MailboxHandler.php index ca69b684..4ef361b4 100644 --- a/model/MailboxHandler.php +++ b/model/MailboxHandler.php @@ -661,7 +661,7 @@ class MailboxHandler extends PFAHandler { return true; } - if(!function_exists('imap_open')) { + if (!function_exists('imap_open')) { trigger_error('imap_open function not present; cannot create_mailbox_subdirs'); return false; } diff --git a/scripts/postfixadmin-cli.php b/scripts/postfixadmin-cli.php index a1b0f564..01b1050a 100644 --- a/scripts/postfixadmin-cli.php +++ b/scripts/postfixadmin-cli.php @@ -409,8 +409,7 @@ require_once(dirname(__FILE__) . '/../common.php'); $dispatcher = new PostfixAdmin($argv); try { $retval = $dispatcher->dispatch(); -} -catch(Exception $e) { +} catch (Exception $e) { $dispatcher->stderr("Execution Exception: " . $e->getMessage()); $retval = 1; }