mirror of
https://github.com/J3vb/OwnCord.git
synced 2026-09-03 03:50:00 +03:00
FetchTextAssetCached served the unauthenticated, unrate-limited client-update endpoint. On TTL expiry every concurrent caller missed the cache and issued its own outbound fetch: a measured 25 requests for 25 callers. Failures were not cached at all, so an upstream outage produced one outbound request per caller for as long as it lasted. Guards the refresh with singleflight so a burst issues one fetch, caches failures for errorCacheTTL (mirroring the release cache's existing cachedErr idiom), and evicts expired keys so the map no longer grows by one entry per release for the process lifetime. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>