Closed waaronking closed 4 years ago
Totals | |
---|---|
Change from base Build 325: | 0.0% |
Covered Lines: | 303 |
Relevant Lines: | 303 |
Per the requirements for this PR, only byteRangePlaceholder
was required, but since the other data was easily accessible, I added byteRangeStrings
and byteRanges
that could be used to refactor/replace some of the logic in https://github.com/vbuch/node-signpdf/blob/develop/src/helpers/extractSignature.js at some point in the future.
Thank you! And thanks for all the work you've put into this project!
Per #98, this PR adds a findByteRange that properly parses the ByteRange field regardless of the spacing included inside.
The function returns a
byteRangePlaceholder
(if it exists), abyteRangeStrings
array containing each byteRangeString in the pdf, and abyteRanges
array of values for each byteRangeString. I've updated the PR to support multiple byteRanges per PDF.