Welcome back bonus: +250 earned credits on the first sign-in after 7+ days away (settings comebackBonus/comebackDays)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
martbost
2026-10-05 08:28:54 -05:00
parent 503a252fc8
commit ec57a926fc
4 changed files with 5 additions and 3 deletions
+2 -1
View File
@@ -667,7 +667,8 @@
if (!window.__lbChecked) { // daily login bonus, once per session (server guards once/day)
window.__lbChecked = true;
api('/api/my/login-bonus').then(r => {
if (r && r.granted > 0) {
if (r && r.comeback > 0) { IAP.status('🎉 Welcome back! +' + r.comeback + ' bonus credits for coming back, plus +' + r.granted + ' for signing in today.', 'ok'); playSound('chaching'); setTimeout(loadDashboard, 900); }
else if (r && r.granted > 0) {
IAP.status('🎁 Daily login bonus: +' + r.granted + ' credits' + (r.streak > 1 ? ' · ' + r.streak + '-day streak' : '') + '!', 'ok');
playSound('chaching'); setTimeout(loadDashboard, 900);
}