All files / src/common is-bn.ts

100% Statements 3/3
81.25% Branches 13/16
100% Functions 1/1
100% Lines 3/3

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 1168x   68x 2x              
const BN_WORD_SIZE = 26;
 
export function isBN(num: any) {
  return (
    num !== null &&
    typeof num === 'object' &&
    num?.constructor?.wordSize === BN_WORD_SIZE &&
    Array.isArray(num?.words)
  );
}