From 75aac412ec3ab256123d6babccdc32d7dc3f7993 Mon Sep 17 00:00:00 2001 From: lingdocs <71590811+lingdocs@users.noreply.github.com> Date: Thu, 16 Sep 2021 14:08:23 -0400 Subject: [PATCH] oops --- functions/src/index.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/functions/src/index.ts b/functions/src/index.ts index 8bdca12..5525608 100644 --- a/functions/src/index.ts +++ b/functions/src/index.ts @@ -16,7 +16,8 @@ export const publishDictionary = functions.runWith({ try { const response = await publish(); res.send(response); - } catch (e: any) { + } catch (e) { + // @ts-ignore res.status(500).send({ ok: false, error: e.message }); } } @@ -39,7 +40,8 @@ export const submissions = functions.runWith({ const response = await receiveSubmissions(suggestions, req.user.level === "editor"); // TODO: WARN IF ANY OF THE EDITS DIDN'T HAPPEN res.send(response); - } catch (e: any) { + } catch (e) { + // @ts-ignore res.status(500).send({ ok: false, error: e.message }); }; }