From 622f8592bcda9cd96f91048da519ba40388ec292 Mon Sep 17 00:00:00 2001
From: Will Hunt <will@half-shot.uk>
Date: Tue, 29 Jan 2019 22:27:43 +0000
Subject: [PATCH] Reject if we fail to handle for some reason

---
 src/discordas.ts | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/discordas.ts b/src/discordas.ts
index 841747a..c445547 100644
--- a/src/discordas.ts
+++ b/src/discordas.ts
@@ -107,6 +107,7 @@ async function run(port: number, fileConfig: DiscordBridgeConfig) {
                     await request.outcomeFrom(Bluebird.resolve(roomhandler.OnEvent(request, context)));
                 } catch (err) {
                     log.error("Exception thrown while handling \"onEvent\" event", err);
+                    await request.outcomeFrom(Bluebird.reject("Failed to handle"));
                 }
             },
             onLog: (line, isError) => {
-- 
GitLab