Files
Stirling-PDF/frontend/editor
Connor Yoh cabba5a94b fix(desktop): key endpoint availability by the endpoint set
Review caught a real fail-open regression. The multiple-endpoint query keyed on
a constant, which asserts the value is caller-independent, but on two paths it
is not: the self-hosted-offline check and the legacy ?endpoints= fallback both
resolve only the endpoints they were handed. Consumers pass disjoint sets, so
whichever mounted first froze a partial map into the shared entry, and a later
consumer projected endpoints nobody had checked. Those read as available on
exactly the paths where desktop means to fail closed, and being mount-order
dependent it would not have reproduced reliably.

Keying by the endpoint set restores the old per-consumer semantics and removes
the mount-order dependence. Prefix invalidation still covers every set, so the
reconnect swap is unaffected. This costs the cross-consumer dedup the PR
claimed: that saving only held while the whole-map response made the shared
entry complete, which those two paths break.

Also stops the readiness effect invalidating on mount, which was forcing a
redundant second fetch behind the first.
2026-09-02 17:48:46 +01:00
..
2026-08-24 20:45:54 +00:00