Various code cleanup.

This commit is contained in:
James Cole
2023-11-05 19:41:37 +01:00
parent a0564751d6
commit 1d2e95f5af
136 changed files with 1171 additions and 514 deletions

View File

@@ -87,7 +87,7 @@ class SetBudget implements ActionInterface
$object = $user->transactionJournals()->find($journal['transaction_journal_id']);
$oldBudget = $object->budgets()->first();
$oldBudgetName = $oldBudget?->name;
if ((int)$oldBudget?->id === (int)$budget->id) {
if ((int)$oldBudget?->id === $budget->id) {
event(new RuleActionFailedOnArray($this->action, $journal, trans('rules.already_linked_to_budget', ['name' => $budget->name])));
return false;
}