mirror of
https://github.com/supermemoryai/supermemory.git
synced 2026-11-12 10:18:11 +08:00
perf: scope message equality check to content+parts instead of full object (#842)
This commit is contained in:
@@ -27,9 +27,9 @@ export function areUIMessageArraysEqual(
|
||||
return false
|
||||
}
|
||||
|
||||
// Compare the entire message using JSON serialization as a fallback
|
||||
// This handles all properties including parts, toolInvocations, etc.
|
||||
if (JSON.stringify(msgA) !== JSON.stringify(msgB)) {
|
||||
if (msgA.content !== msgB.content) return false
|
||||
|
||||
if (JSON.stringify(msgA.parts) !== JSON.stringify(msgB.parts)) {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user