Merge pull request #737 from OpenSignLabs/signPdf

fix: resend mail API is not working
This commit is contained in:
Amol
2024-05-14 16:44:42 +05:30
committed by GitHub
@@ -33,10 +33,11 @@ export default async function resendMail(request, response) {
docQuery.notEqualTo('IsCompleted', true);
docQuery.notEqualTo('IsDeclined', true);
docQuery.notEqualTo('IsArchive', true);
docQuery.lessThanOrEqualTo('ExpiryDate', new Date());
docQuery.greaterThanOrEqualTo('ExpiryDate', new Date());
docQuery.exists('SignedUrl');
const resDoc = await docQuery.first({ useMasterKey: true });
// console.log("resDoc ",resDoc)
if (resDoc) {
const _resDoc = resDoc.toJSON();
const contact = _resDoc.Signers.find(x => x.Email === userMail);