Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
Various code cleaning things.
James Coleb1c2f8faa1c2
diff --git a/app/Helpers/Csv/Importer.php b/app/Helpers/Csv/Importer.phpindex 0df9e8656a..bed0cb6b0a 100644--- a/app/Helpers/Csv/Importer.php+++ b/app/Helpers/Csv/Importer.php@@ -371,8 +371,8 @@ class Importer/** @var Rule $rule */foreach ($group->rules as $rule) {- $processor = new Processor($rule, $journal);- $processor->handle();+ $processor = Processor::make($rule);+ $processor->handleTransactionJournal($journal);if ($rule->stop_processing) {break;}diff --git a/app/Http/Controllers/Auth/AuthController.php b/app/Http/Controllers/Auth/AuthController.phpindex 93376784cd..7c33242577 100644--- a/app/Http/Controllers/Auth/AuthController.php+++ b/app/Http/Controllers/Auth/AuthController.php@@ -97,6 +97,8 @@ class AuthController extends Controller* @param \Illuminate\Http\Request $request** @return \Illuminate\Http\Response+ * @throws FireflyException+ * @throws \Illuminate\Foundation\Validation\ValidationException*/public function register(Request $request){diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.phpindex d87d0e6e4a..d0f268d81f 100644--- a/app/Http/Controllers/HomeController.php+++ b/app/Http/Controllers/HomeController.php@@ -27,11 +27,6 @@ class HomeController extends Controllerparent::__construct();}- public function displayError() {- throw new FireflyException('A very simple test error.');- }--public function dateRange(){$start = new Carbon(Input::get('start'));@@ -47,6 +42,11 @@ class HomeController extends ControllerSession::put('end', $end);}+ public function displayError()+ {+ throw new FireflyException('A very simple test error.');+ }+/*** @return \Illuminate\Http\RedirectResponse*/diff --git a/app/Http/Controllers/RuleController.php b/app/Http/Controllers/RuleController.phpindex 194d12e8fd..4a79966139 100644--- a/app/Http/Controllers/RuleController.php+++ b/app/Http/Controllers/RuleController.php@@ -139,7 +139,8 @@ class RuleController extends Controller}/**- * @param Rule $rule+ * @param RuleRepositoryInterface $repository+ * @param Rule $rule** @return View*/@@ -174,6 +175,8 @@ class RuleController extends Controller}/**+ * @param RuleGroupRepositoryInterface $repository+ ** @return View*/public function index(RuleGroupRepositoryInterface $repository)@@ -263,6 +266,8 @@ class RuleController extends Controller}/**+ * @param TestRuleFormRequest $request+ ** @return \Illuminate\View\View*/public function testTriggers(TestRuleFormRequest $request)diff --git a/app/Models/Role.php b/app/Models/Role.phpindex 9fb22152df..d7b667f519 100644--- a/app/Models/Role.php+++ b/app/Models/Role.php@@ -7,6 +7,11 @@ use Illuminate\Database\Eloquent\Model;use Illuminate\Database\Eloquent\Relations\BelongsToMany;+/**+ * Class Role+ *+ * @package FireflyIII\Models+ */class Role extends Model{diff --git a/app/Repositories/Account/AccountRepository.php b/app/Repositories/Account/AccountRepository.phpindex 7a90bb7386..6c5eef63d0 100644--- a/app/Repositories/Account/AccountRepository.php+++ b/app/Repositories/Account/AccountRepository.php@@ -455,6 +455,7 @@ class AccountRepository implements AccountRepositoryInterface* @param array $data** @return Account+ * @throws FireflyException*/private function storeAccount(array $data): Account{diff --git a/app/Repositories/Journal/JournalRepository.php b/app/Repositories/Journal/JournalRepository.phpindex 1abdb1b2ec..2a69fbdb04 100644--- a/app/Repositories/Journal/JournalRepository.php+++ b/app/Repositories/Journal/JournalRepository.php@@ -112,6 +112,8 @@ class JournalRepository implements JournalRepositoryInterface* @param int $offset* @param int $page*+ * @param int $pagesize+ ** @return LengthAwarePaginator*/public function getJournalsOfTypes(array $types, int $offset, int $page, int $pagesize = 50)@@ -347,7 +349,7 @@ class JournalRepository implements JournalRepositoryInterface* @param array $data** @return array- *+ * @throws FireflyException* @SuppressWarnings(PHPMD.CyclomaticComplexity)*/protected function storeAccounts(TransactionType $type, array $data)diff --git a/app/Rules/TransactionMatcher.php b/app/Rules/TransactionMatcher.phpindex 2d66ff9e41..2298bc4ad3 100644--- a/app/Rules/TransactionMatcher.php+++ b/app/Rules/TransactionMatcher.php@@ -36,9 +36,8 @@ class TransactionMatcher/*** Find matching transactions for the current set of triggers*- * @param int $maxResults The maximum number of transactions returned- ** @return array+ **/public function findMatchingTransactions(){diff --git a/app/Rules/Triggers/TriggerFactory.php b/app/Rules/Triggers/TriggerFactory.phpindex d104070e06..bab4baf49f 100644--- a/app/Rules/Triggers/TriggerFactory.php+++ b/app/Rules/Triggers/TriggerFactory.php@@ -48,6 +48,8 @@ class TriggerFactory* @param string $triggerType* @param string $triggerValue*+ * @param bool $stopProcessing+ ** @return AbstractTrigger* @throws FireflyException*/diff --git a/config/firefly.php b/config/firefly.phpindex bdf610da13..290e9a8aba 100644--- a/config/firefly.php+++ b/config/firefly.php@@ -221,9 +221,9 @@ return [],'test-triggers' => [// The maximum number of transactions shown when testing a list of triggers- 'limit' => 10,+ 'limit' => 50,// The maximum number of transactions to analyse, when testing a list of triggers- 'range' => 100+ 'range' => 1000]];