mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-20 11:48:27 -06:00
Fix null pointer in command
This commit is contained in:
parent
95181a0a6a
commit
2d47ee7e21
@ -57,8 +57,6 @@ class MigrateRecurrenceMeta extends Command
|
||||
|
||||
return 0;
|
||||
}
|
||||
$this->warn('Congrats, you found the skeleton command. Boo!');
|
||||
|
||||
$count = $this->migrateMetaData();
|
||||
|
||||
if (0 === $count) {
|
||||
@ -106,6 +104,9 @@ class MigrateRecurrenceMeta extends Command
|
||||
private function migrateEntry(RecurrenceMeta $meta): int
|
||||
{
|
||||
$recurrence = $meta->recurrence;
|
||||
if (null === $recurrence) {
|
||||
return 0;
|
||||
}
|
||||
$firstTransaction = $recurrence->recurrenceTransactions()->first();
|
||||
if (null === $firstTransaction) {
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user