Skip to content

Firefly III: a personal finances manager

Clean up some old code.

James Coleb855c54e8170
diff --git a/app/Http/Requests/TestRuleFormRequest.php b/app/Http/Requests/TestRuleFormRequest.php
index 5cb45c8a30..41f2614d60 100644
--- a/app/Http/Requests/TestRuleFormRequest.php
+++ b/app/Http/Requests/TestRuleFormRequest.php
@@ -23,7 +23,7 @@ declare(strict_types=1);
namespace FireflyIII\Http\Requests;
/**
- * Class RuleFormRequest.
+ * Class TestRuleFormRequest.
*
* @codeCoverageIgnore
*/
diff --git a/app/Import/Routine/YnabRoutine.php b/app/Import/Routine/YnabRoutine.php
index 6540d36c19..f49cdd38c7 100644
--- a/app/Import/Routine/YnabRoutine.php
+++ b/app/Import/Routine/YnabRoutine.php
@@ -123,23 +123,6 @@ class YnabRoutine implements RoutineInterface
return;
}
- // if ('match_accounts' === $this->importJob->stage) {
- // // $this->repository->setStatus($this->importJob, 'running');
- // /** @var StageGetBudgetsHandler $handler */
- // $handler = app(StageGetBudgetsHandler::class);
- // $handler->setImportJob($this->importJob);
- // $handler->run();
- // $this->repository->setStage($this->importJob, 'get_transactions');
- // }
- //
- // if ('get_transactions' === $this->importJob->stage) {
- // // $this->repository->setStatus($this->importJob, 'running');
- // /** @var StageGetBudgetsHandler $handler */
- // $handler = app(StageGetBudgetsHandler::class);
- // $handler->setImportJob($this->importJob);
- // $handler->run();
- // $this->repository->setStage($this->importJob, 'get_transactions');
- // }
throw new FireflyException(sprintf('YNAB import routine cannot handle stage "%s"', $this->importJob->stage));
}
}
diff --git a/app/Services/Internal/Support/JournalServiceTrait.php b/app/Services/Internal/Support/JournalServiceTrait.php
index 61f30ef5c1..ab66e38ff8 100644
--- a/app/Services/Internal/Support/JournalServiceTrait.php
+++ b/app/Services/Internal/Support/JournalServiceTrait.php
@@ -23,6 +23,7 @@ declare(strict_types=1);
namespace FireflyIII\Services\Internal\Support;
+use Exception;
use FireflyIII\Factory\BillFactory;
use FireflyIII\Factory\TagFactory;
use FireflyIII\Factory\TransactionJournalMetaFactory;
@@ -128,7 +129,11 @@ trait JournalServiceTrait
}
$note = $journal->notes()->first();
if (null !== $note) {
- $note->delete();
+ try {
+ $note->delete();
+ } catch (Exception $e) {
+ Log::debug(sprintf('Journal service trait could not delete note: %s', $e->getMessage()));
+ }
}