fix(session-memory): use HHMMSS slug to prevent same-minute overwrites
Custom content and no-session paths fell through to HHMM (4-char) timestamp slug. Two /new events in the same minute would overwrite. HHMMSS makes collisions require same-second timing.
This commit is contained in:
parent
423dce7ccd
commit
6b998ff746
@ -322,7 +322,7 @@ const saveSessionToMemory: HookHandler = async (event) => {
|
||||
// If no slug, use timestamp
|
||||
if (!slug) {
|
||||
const timeSlug = now.toISOString().split("T")[1].split(".")[0].replace(/:/g, "");
|
||||
slug = timeSlug.slice(0, 4); // HHMM
|
||||
slug = timeSlug.slice(0, 6); // HHMMSS — seconds prevent same-minute overwrites
|
||||
log.debug("Using fallback timestamp slug", { slug });
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user