Various code fixes.

This commit is contained in:
James Cole
2022-10-31 05:53:36 +01:00
parent 0059ed7bde
commit 249b0c3377
88 changed files with 180 additions and 180 deletions

View File

@@ -77,7 +77,7 @@ class DeleteEmptyJournals extends Command
// uneven number, delete journal and transactions:
try {
TransactionJournal::find((int)$row->transaction_journal_id)->delete();
} catch (Exception $e) {
} catch (Exception $e) {
Log::info(sprintf('Could not delete journal: %s', $e->getMessage()));
}
@@ -104,7 +104,7 @@ class DeleteEmptyJournals extends Command
foreach ($set as $entry) {
try {
TransactionJournal::find($entry->id)->delete();
} catch (Exception $e) {
} catch (Exception $e) {
Log::info(sprintf('Could not delete entry: %s', $e->getMessage()));
}

View File

@@ -147,7 +147,7 @@ class DeleteOrphanedTransactions extends Command
if ($journal) {
try {
$journal->delete();
} catch (Exception $e) {
} catch (Exception $e) {
Log::info(sprintf('Could not delete journal %s', $e->getMessage()));
}
}

View File

@@ -62,7 +62,7 @@ class DeleteZeroAmount extends Command
$this->info(sprintf('Deleted transaction journal #%d because the amount is zero (0.00).', $journal->id));
try {
$journal->delete();
} catch (Exception $e) {
} catch (Exception $e) {
$this->line($e->getMessage());
}

View File

@@ -121,7 +121,7 @@ class ExportData extends Command
$exporter->setExportBills($options['export']['bills']);
$exporter->setExportPiggies($options['export']['piggies']);
$data = $exporter->export();
if (0 === count ($data)) {
if (0 === count($data)) {
$this->error('You must export *something*. Use --export-transactions or another option. See docs.firefly-iii.org');
}
$returnCode = 0;

View File

@@ -83,7 +83,7 @@ class MigrateJournalNotes extends Command
Log::debug(sprintf('Migrated meta note #%d to Note #%d', $meta->id, $note->id));
try {
$meta->delete();
} catch (Exception $e) {
} catch (Exception $e) {
Log::error(sprintf('Could not delete old meta entry #%d: %s', $meta->id, $e->getMessage()));
}