Make progressive achievements get notifications when complete

This commit is contained in:
2026-08-21 17:02:12 +10:00
parent 3ae1e75275
commit c0b8d10add
2 changed files with 3 additions and 2 deletions
@@ -98,7 +98,8 @@ class AchievementService
->where('achievement_id', $achievement->id)
->first();
$alreadyUnlocked = $existing !== null;
$alreadyUnlocked = $existing !== null
&& (! $achievement->progressive || $existing->progress >= $achievement->threshold);
UserAchievement::updateOrCreate(
['user_id' => $user->id, 'achievement_id' => $achievement->id],