Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/services/insight-trigger.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ function isInCooldown(latest) {
if (latest.user_action === 'snoozed') {
return minutesAgo(latest.created_at) < SNOOZE_MINUTES();
}
// Pending (null) is the only other state that should gate new recommendations.
// 'dismissed', 'accepted', 'expired' all mean "the user/system is done with this one" —
// a new recommendation may fire immediately.
if (latest.user_action !== null) return false;
return minutesAgo(latest.created_at) < COOLDOWN_MINUTES();
}

Expand Down
Loading