Skip to content

fix: report actual cache hit status instead of hardcoding cached false - #205

Merged
collinsezedike merged 2 commits into
mainfrom
fix/vault-cached-field
Jun 21, 2026
Merged

collinsezedike merged 2 commits into
mainfrom
fix/vault-cached-field

Conversation

@collinsezedike

@collinsezedike collinsezedike commented Jun 21, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Added isVaultCacheWarm() to @meridian/stellar-sdk-helpers to expose whether a valid in-memory cache entry exists
  • Both the Vercel handler and the Fastify route now call it before fetchAllVaults() and return the real cached boolean
  • No change to fetchAllVaults return type; the helper is a pure state check on the module-level cache variable

Test plan

  • First request returns cached: false; subsequent request within 60s returns cached: true
  • All sdk-helpers tests pass

Closes #184

@vercel

vercel Bot commented Jun 21, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
meridian Ready Ready Preview, Comment Jun 21, 2026 12:41pm

@collinsezedike
collinsezedike force-pushed the fix/vault-cached-field branch from c877d43 to 9e5ef04 Compare June 21, 2026 12:40
@collinsezedike
collinsezedike merged commit a07d42d into main Jun 21, 2026
5 checks passed
@collinsezedike
collinsezedike deleted the fix/vault-cached-field branch June 21, 2026 12:42

This branch was successfully deployed

1 active deployment
Preview — 9e5ef04a Deployed Jun 21, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Fix] vault API response always returns cached: false even when serving a warm cache hit

1 participant