mirror of
https://github.com/OpenSignLabs/OpenSign.git
synced 2026-08-17 21:25:54 +02:00
21 lines
545 B
JavaScript
21 lines
545 B
JavaScript
const ERROR_TYPE_UNKNOWN = 1,
|
|
ERROR_TYPE_INPUT = 2,
|
|
ERROR_TYPE_PARSE = 3,
|
|
ERROR_VERIFY_SIGNATURE = 4;
|
|
class SignPdfError extends Error {
|
|
constructor(R, E = ERROR_TYPE_UNKNOWN) {
|
|
super(R), (this.type = E);
|
|
}
|
|
}
|
|
(SignPdfError.TYPE_UNKNOWN = ERROR_TYPE_UNKNOWN),
|
|
(SignPdfError.TYPE_INPUT = ERROR_TYPE_INPUT),
|
|
(SignPdfError.TYPE_PARSE = ERROR_TYPE_PARSE),
|
|
(SignPdfError.VERIFY_SIGNATURE = ERROR_VERIFY_SIGNATURE);
|
|
export {
|
|
ERROR_TYPE_UNKNOWN,
|
|
ERROR_TYPE_INPUT,
|
|
ERROR_TYPE_PARSE,
|
|
ERROR_VERIFY_SIGNATURE,
|
|
SignPdfError,
|
|
};
|