-
-
Notifications
You must be signed in to change notification settings - Fork 178
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
🐛 Signer.sign() is an async method so the typing should indicate it c…
…an be a promise At the moment the typings are wrong because the sign function is reported to be `sign(pdfBuffer: Buffer) => Buffer`. However, this is not a correct typing as the method is expected to return a promise as it is `async`. The sign method can also return a Buffer (sync) as is done in the P12Signer. Therefore the typings should be `sign(pdfBuffer: Buffer) => Promise<Buffer> | Buffer`.
- Loading branch information
Showing
6 changed files
with
13 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
export class Signer { | ||
/** | ||
* @param {Buffer} pdfBuffer | ||
* @returns {Buffer} | ||
* @returns {Promise<Buffer> | Buffer} | ||
*/ | ||
sign(pdfBuffer: Buffer): Buffer; | ||
sign(pdfBuffer: Buffer): Promise<Buffer> | Buffer; | ||
} | ||
//# sourceMappingURL=Signer.d.ts.map |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters