From 6c130878447acdee1096b526312913360a6fc884 Mon Sep 17 00:00:00 2001 From: Leo Horie Date: Mon, 9 Feb 2015 23:27:31 -0500 Subject: [PATCH] #448 fix flatten edge case --- mithril.js | 1 + 1 file changed, 1 insertion(+) diff --git a/mithril.js b/mithril.js index a2bc57d9..7c8b8e35 100644 --- a/mithril.js +++ b/mithril.js @@ -117,6 +117,7 @@ var m = (function app(window, undefined) { if (type.call(data[i]) === ARRAY) { data = data.concat.apply([], data); i-- //check current index again and flatten until there are no more nested arrays at that index + len = data.length } }