From ce748f9f71fa729ba8bdb13f3378210768369164 Mon Sep 17 00:00:00 2001 From: Leo Horie Date: Thu, 26 May 2016 11:30:27 -0400 Subject: [PATCH] check for existence of Promise before doing check against it --- mithril.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mithril.js b/mithril.js index 464e8a5f..01e0794a 100644 --- a/mithril.js +++ b/mithril.js @@ -1338,7 +1338,7 @@ } m.prop = function (store) { - if ((store != null && isObject(store) || isFunction(store)) || store instanceof window.Promise && + if ((store != null && isObject(store) || isFunction(store)) || (typeof Promise !== "undefined" && store instanceof Promise) && isFunction(store.then)) { return propify(store) }