mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Basic amount fix
This commit is contained in:
parent
0b49e9b8a8
commit
70c08d6b50
@ -206,6 +206,14 @@ class BudgetLimitController extends Controller
|
||||
$amount = '0';
|
||||
}
|
||||
|
||||
// sanity check on amount:
|
||||
if ((float) $amount === 0.0) {
|
||||
$amount = '1';
|
||||
}
|
||||
if ((int) $amount > 65536) {
|
||||
$amount = '65536';
|
||||
}
|
||||
|
||||
$limit = $this->blRepository->update($budgetLimit, ['amount' => $amount]);
|
||||
$array = $limit->toArray();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user