SurfSense/surfsense_web/lib/query-client
guangyang1206 3504be3413 fix(web): make cacheKeys.*.withQueryParams order-stable (sort entries)
Fixes #1370

Object.values() produces order-dependent cache keys because the order of values depends on the order of keys in the object. This causes the same logical query to produce different cache keys when the parameter object has keys in different orders.

Added stableEntries() helper that:
1. Filters out undefined values
2. Sorts entries by key name
3. Returns flat array of [key, value] pairs

This ensures cache key identity is stable regardless of parameter object key order.

Co-authored-by: guangyang1206 <guangyang1206@users.noreply.github.com>
2026-05-16 12:10:04 +08:00
..
cache-keys.ts fix(web): make cacheKeys.*.withQueryParams order-stable (sort entries) 2026-05-16 12:10:04 +08:00
client.ts feat: add processing mode support for document uploads and ETL pipeline, improded error handling ux 2026-04-14 21:26:00 -07:00
query-client.provider.tsx chore: linting 2026-04-02 19:45:28 -07:00