Skip to content

🔥 The free & Open Source DocuSign alternative

changed callwwebhook

prafull-opensignlabscaa1dfaf3454
diff --git a/microfrontends/SignDocuments/src/Component/PdfRequestFiles.js b/microfrontends/SignDocuments/src/Component/PdfRequestFiles.js
index 924c7c5c1..53c45f0df 100644
--- a/microfrontends/SignDocuments/src/Component/PdfRequestFiles.js
+++ b/microfrontends/SignDocuments/src/Component/PdfRequestFiles.js
@@ -612,6 +612,10 @@ function PdfRequestFiles() {
.then(async (result) => {
const res = result.data;
if (res) {
+ const currentDecline = {
+ currnt: "YouDeclined",
+ isDeclined: true
+ };
const params = {
event: "declined",
body: {
@@ -628,24 +632,23 @@ function PdfRequestFiles() {
declinedAt: new Date()
}
};
- const res = await axios.post(
- `${localStorage.getItem("baseUrl")}functions/callwebhook`,
- params,
- {
- headers: {
- "Content-Type": "application/json",
- "X-Parse-Application-Id": localStorage.getItem("parseAppId"),
- sessiontoken: localStorage.getItem("accesstoken")
- }
- }
- );
- console.log("res ", res.data);
- const currentDecline = {
- currnt: "YouDeclined",
- isDeclined: true
- };
setIsDecline(currentDecline);
setIsUiLoading(false);
+ try {
+ await axios.post(
+ `${localStorage.getItem("baseUrl")}functions/callwebhook`,
+ params,
+ {
+ headers: {
+ "Content-Type": "application/json",
+ "X-Parse-Application-Id": localStorage.getItem("parseAppId"),
+ sessiontoken: localStorage.getItem("accesstoken")
+ }
+ }
+ );
+ } catch (err) {
+ console.log("Err ", err);
+ }
}
})
.catch((err) => {