mirror of
https://github.com/Permissionless-Software-Foundation/psf-bch-api.git
synced 2026-09-21 16:52:00 -07:00
863 B
863 B
2026-03-16 Update Log
Summary
Reduced noisy error logging for common SLP transaction misses in the /v6/slp/txid path.
Changes Made
- Updated
src/use-cases/slp-use-cases.jsingetTxid():- Added a guard for expected missing-record errors (
404+Key not found in database). - Skips
wlogger.error()for that specific, common case. - Still rethrows the error so API response behavior is unchanged.
- Added a guard for expected missing-record errors (
- Updated
src/controllers/rest-api/slp/controller.jsinhandleError():- Added the same guard to suppress duplicate error-level logs for the same expected case.
- Keeps normal error logging for all other errors.
Outcome
- The common "Key not found in database" case no longer pollutes error logs.
- Unexpected failures continue to be logged at error level.
- Client-facing status and error message behavior remains unchanged.