Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.
fix: catch error if notifications job cannot be initiated
Marc Seitz7e1633a669e0
diff --git a/pages/api/views.ts b/pages/api/views.tsindex 26826e1c..1c9778d6 100644--- a/pages/api/views.ts+++ b/pages/api/views.ts@@ -251,7 +251,15 @@ export default async function handle(Authorization: `Bearer ${process.env.INTERNAL_API_KEY}`,},body: JSON.stringify({ viewId: newView.id }),- });+ })+ .then(() => {})+ .catch((error) => {+ log({+ message: `Failed to fetch notifications job in _/api/views_ route for linkId: ${linkId}. \n\n Error: ${error} \n\n*Metadata*: \`{viewId: ${newView.id}}\``,+ type: "error",+ mention: true,+ });+ });console.timeEnd("sendemail");}