Skip to content

Commit

Permalink
fix: throw error on invalid chainhook payloads (#117)
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelcr committed Jun 30, 2023
1 parent f184576 commit e639343
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/chainhook/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export async function processInscriptionFeed(payload: unknown, db: PgStore): Pro
if (!ChainhookPayloadCType.Check(payload)) {
const errors = [...ChainhookPayloadCType.Errors(payload)];
logger.error(errors, `[inscription_feed] invalid payload`);
return;
throw new Error(`Unable to process invalid chainhook payload`);
}
await db.updateInscriptions(payload);
}

0 comments on commit e639343

Please sign in to comment.