From d68952fde33141497d109a832b36d7c4ff6e85af Mon Sep 17 00:00:00 2001 From: Jesse Shawl Date: Wed, 27 Mar 2024 07:02:50 -0500 Subject: [PATCH] log log response --- src/log.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/log.js b/src/log.js index 6c33c1c..d9187cf 100644 --- a/src/log.js +++ b/src/log.js @@ -1,5 +1,5 @@ export const log = async ({ env, user_id, tags }) => { - await fetch('https://api.logsnag.com/v1/log', { + const response = await fetch('https://api.logsnag.com/v1/log', { headers: { 'Content-Type': 'application/json', Authorization: `Bearer ${env.LOGSNAG_API_TOKEN}`, @@ -14,4 +14,7 @@ export const log = async ({ env, user_id, tags }) => { }), method: 'POST', }); + const data = await response.json(); + // eslint-disable-next-line no-console + console.log(data); };