Use PSR-12 code style

This commit is contained in:
James Cole
2022-10-30 14:24:37 +01:00
parent f53923f16c
commit f52675068b
151 changed files with 251 additions and 403 deletions

View File

@@ -31,5 +31,4 @@ namespace FireflyIII\Validation\Account;
*/
trait AccountValidatorProperties
{
}

View File

@@ -153,7 +153,7 @@ trait DepositValidation
$result = true;
// set the source to be a (dummy) revenue account.
$account = new Account;
$account = new Account();
$accountType = AccountType::whereType(AccountType::REVENUE)->first();
$account->accountType = $accountType;
$this->source = $account;

View File

@@ -24,7 +24,6 @@ declare(strict_types=1);
namespace FireflyIII\Validation\Account;
use FireflyIII\Models\Account;
use FireflyIII\Models\AccountType;
use Log;
@@ -34,7 +33,6 @@ use Log;
*/
trait LiabilityValidation
{
/**
* @param array $array
*
@@ -89,7 +87,7 @@ trait LiabilityValidation
}
if (true === $result) {
// set the source to be a (dummy) revenue account.
$account = new Account;
$account = new Account();
$accountType = AccountType::whereType(AccountType::LIABILITY_CREDIT)->first();
$account->accountType = $accountType;
$this->source = $account;
@@ -97,5 +95,4 @@ trait LiabilityValidation
return $result;
}
}

View File

@@ -139,7 +139,7 @@ trait OBValidation
$result = true;
// set the source to be a (dummy) initial balance account.
$account = new Account;
$account = new Account();
$accountType = AccountType::whereType(AccountType::INITIAL_BALANCE)->first();
$account->accountType = $accountType;
$this->source = $account;

View File

@@ -86,7 +86,7 @@ trait ReconciliationValidation
// source to the asset account that is the destination.
if (null === $accountId && null === $accountName) {
Log::debug('The source is valid because ID and name are NULL.');
$this->source = new Account;
$this->source = new Account();
return true;
}
@@ -107,5 +107,4 @@ trait ReconciliationValidation
return true;
}
}