From 12f68a6e3ae363d1d8ae31bdc056bb768b1c25e9 Mon Sep 17 00:00:00 2001 From: David Goodwin Date: Thu, 13 Aug 2020 15:27:47 +0100 Subject: [PATCH] composer format time --- model/AliasHandler.php | 2 +- tests/AdminHandlerTest.php | 2 -- tests/AliasHandlerTest.php | 18 ++++++------------ 3 files changed, 7 insertions(+), 15 deletions(-) diff --git a/model/AliasHandler.php b/model/AliasHandler.php index f680a994..9119cfdd 100644 --- a/model/AliasHandler.php +++ b/model/AliasHandler.php @@ -401,7 +401,7 @@ class AliasHandler extends PFAHandler { $errors[] = "$singlegoto: $email_check"; } } - if($this->called_by != "MailboxHandler" && $this->id == $singlegoto) { + if ($this->called_by != "MailboxHandler" && $this->id == $singlegoto) { // The MailboxHandler needs to create an alias that points to itself (for the mailbox) // Otherwise, disallow such aliases as they cause severe trouble in the mail system $errors[] = "$singlegoto: " . Config::Lang('alias_points_to_itself'); diff --git a/tests/AdminHandlerTest.php b/tests/AdminHandlerTest.php index 5843aa9d..c13f9502 100644 --- a/tests/AdminHandlerTest.php +++ b/tests/AdminHandlerTest.php @@ -12,8 +12,6 @@ class AdminHandlerTest extends \PHPUnit\Framework\TestCase { $this->assertEmpty($results); } - - } /* vim: set expandtab softtabstop=4 tabstop=4 shiftwidth=4: */ diff --git a/tests/AliasHandlerTest.php b/tests/AliasHandlerTest.php index 55b70ba9..d75a7922 100644 --- a/tests/AliasHandlerTest.php +++ b/tests/AliasHandlerTest.php @@ -1,9 +1,7 @@ getList(""); $this->assertTrue($list); @@ -11,8 +9,7 @@ class AliasHandlerTest extends \PHPUnit\Framework\TestCase $this->assertEmpty($results); } - public function tearDown(): void - { + public function tearDown(): void { $_SESSION = []; db_query('DELETE FROM alias'); db_query('DELETE FROM domain_admins'); @@ -21,8 +18,7 @@ class AliasHandlerTest extends \PHPUnit\Framework\TestCase parent::tearDown(); } - public function testCannotAddAliasUntilDomainIsThere() - { + public function testCannotAddAliasUntilDomainIsThere() { // Fake us being an admin. @@ -56,8 +52,7 @@ class AliasHandlerTest extends \PHPUnit\Framework\TestCase /** * @see https://github.com/postfixadmin/postfixadmin/pull/375 and https://github.com/postfixadmin/postfixadmin/issues/358 */ - public function testCannotAddAliasThatPointsToItself() - { + public function testCannotAddAliasThatPointsToItself() { // Fake being an admin. $_SESSION = [ 'sessid' => [ @@ -140,8 +135,7 @@ class AliasHandlerTest extends \PHPUnit\Framework\TestCase ], $x->errormsg); } - public function testAddingDataEtc() - { + public function testAddingDataEtc() { // Fake being an admin. $_SESSION = [ 'sessid' => [