mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Small php fixes.
This commit is contained in:
@@ -57,8 +57,6 @@ class CorrectsPiggyBanks extends Command
|
||||
$event->transaction_journal_id = null;
|
||||
$event->save();
|
||||
++$count;
|
||||
|
||||
continue;
|
||||
}
|
||||
}
|
||||
if (0 !== $count) {
|
||||
|
@@ -71,7 +71,6 @@ class RestoresOAuthKeys extends Command
|
||||
$this->storeKeysInDB();
|
||||
$this->friendlyInfo('Stored OAuth keys in database.');
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -515,7 +515,7 @@ class ForcesDecimalSize extends Command
|
||||
continue;
|
||||
}
|
||||
// fix $field by rounding it down correctly.
|
||||
$pow = (float) 10 ** $currency->decimal_places;
|
||||
$pow = 10.0 ** $currency->decimal_places;
|
||||
$correct = bcdiv((string) round((float) $value * $pow), (string) $pow, 12);
|
||||
$this->friendlyWarning(sprintf('Transaction #%d has amount with value "%s", this has been corrected to "%s".', $item->id, $value, $correct));
|
||||
|
||||
@@ -546,7 +546,7 @@ class ForcesDecimalSize extends Command
|
||||
continue;
|
||||
}
|
||||
// fix $field by rounding it down correctly.
|
||||
$pow = (float) 10 ** $currency->decimal_places;
|
||||
$pow = 10.0 ** $currency->decimal_places;
|
||||
$correct = bcdiv((string) round((float) $value * $pow), (string) $pow, 12);
|
||||
$this->friendlyWarning(
|
||||
sprintf('Transaction #%d has foreign amount with value "%s", this has been corrected to "%s".', $item->id, $value, $correct)
|
||||
|
@@ -157,7 +157,6 @@ class UpgradesLiabilitiesEight extends Command
|
||||
$service = new TransactionGroupDestroyService();
|
||||
$service->destroy($group);
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user