Prevent a loop.

This commit is contained in:
James Cole
2025-08-21 20:31:32 +02:00
parent 6c5ddfcb8a
commit 1ba641c279
9 changed files with 14 additions and 7 deletions

View File

@@ -268,7 +268,7 @@ class BudgetRepository implements BudgetRepositoryInterface, UserGroupInterface
*/
foreach ($budgets as $index => $budget) {
$budget->order = $index + 1;
$budget->save();
$budget->saveQuietly();
}
// other budgets, set to 0.
$this->user->budgets()->where('active', 0)->update(['order' => 0]);