diff --git a/typescript/src/lib/bitcoin/header.ts b/typescript/src/lib/bitcoin/header.ts index 06531d933..99faa237a 100644 --- a/typescript/src/lib/bitcoin/header.ts +++ b/typescript/src/lib/bitcoin/header.ts @@ -147,7 +147,9 @@ export function validateBitcoinHeadersChain( if ( !previousBlockHeaderHash.equals(currentHeader.previousBlockHeaderHash) ) { - throw new Error("Invalid headers chain") + throw new Error( + `Invalid headers chain; problem with header index: ${index}` + ) } }