From f4ca30bb381c418abd76ab39315f20d29c7fd6d1 Mon Sep 17 00:00:00 2001 From: David Baker Date: Thu, 29 Oct 2015 18:12:42 +0000 Subject: [PATCH] Throw exception if EventTile is instantiated with an event type it doesn't support. --- src/skins/vector/views/molecules/EventTile.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/skins/vector/views/molecules/EventTile.js b/src/skins/vector/views/molecules/EventTile.js index 389b8b4012..b92ab18bec 100644 --- a/src/skins/vector/views/molecules/EventTile.js +++ b/src/skins/vector/views/molecules/EventTile.js @@ -76,7 +76,7 @@ module.exports = React.createClass({ // This shouldn't happen: the caller should check we support this type // before trying to instantiate us if (!EventTileType) { - return null; + throw new Error("Event type not supported"); } var classes = classNames({