Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
Add some debug info
James Cole9a52cfbfbe2b
diff --git a/app/Api/V1/Controllers/TransactionController.php b/app/Api/V1/Controllers/TransactionController.phpindex 717598f32f..a14ea77e8b 100644--- a/app/Api/V1/Controllers/TransactionController.php+++ b/app/Api/V1/Controllers/TransactionController.php@@ -283,7 +283,7 @@ class TransactionController extends Controllertry {$transactionGroup = $this->groupRepository->store($data);} catch (DuplicateTransactionException $e) {- Log::warning('Caught a duplicate. Return error message.');+ Log::warning('Caught a duplicate transaction. Return error message.');// return bad validation message.// TODO use Laravel's internal validation thing to do this.$response = [diff --git a/app/Factory/TransactionJournalFactory.php b/app/Factory/TransactionJournalFactory.phpindex e40043e593..58eddad0f9 100644--- a/app/Factory/TransactionJournalFactory.php+++ b/app/Factory/TransactionJournalFactory.php@@ -428,7 +428,7 @@ class TransactionJournalFactory->first();}if (null !== $result) {- Log::warning('Found a duplicate!');+ Log::warning(sprintf('Found a duplicate in errorIfDuplicate because hash %s is not unique!', $hash));throw new DuplicateTransactionException(sprintf('Duplicate of transaction #%d.', $result->transactionJournal->transaction_group_id));}}diff --git a/app/Repositories/TransactionGroup/TransactionGroupRepository.php b/app/Repositories/TransactionGroup/TransactionGroupRepository.phpindex e1444af843..98c489b8b7 100644--- a/app/Repositories/TransactionGroup/TransactionGroupRepository.php+++ b/app/Repositories/TransactionGroup/TransactionGroupRepository.php@@ -346,6 +346,7 @@ class TransactionGroupRepository implements TransactionGroupRepositoryInterfaceLog::warning('Group repository caught group factory with a duplicate exception!');throw new DuplicateTransactionException($e->getMessage());} catch(FireflyException $e) {+ Log::warning('Group repository caught group factory with an exception!');Log::error($e->getMessage());Log::error($e->getTraceAsString());throw new FireflyException($e->getMessage());