Skip to content
Merged
Show file tree
Hide file tree
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
6 changes: 6 additions & 0 deletions .changeset/member-event-days-rounding.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"adcontextprotocol": patch
---

Match the 3.1 line's upcoming-event day calculation in member context prompts
so events exactly five days out do not intermittently render as four days.
2 changes: 1 addition & 1 deletion server/src/addie/member-context.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1564,7 +1564,7 @@ export function formatMemberContextForPrompt(context: MemberContext, channel: 'w
// Upcoming registered event — context for time-bound discussions.
if (context.next_event) {
const e = context.next_event;
const days = Math.floor(
const days = Math.round(
(e.starts_at.getTime() - Date.now()) / (24 * 60 * 60 * 1000)
);
lines.push('');
Expand Down
Loading