From 33ac4fc7d1dd1d9af7ce81a61d474e734a1b3450 Mon Sep 17 00:00:00 2001 From: Leo Horie Date: Thu, 5 Jun 2014 22:11:51 -0400 Subject: [PATCH] reference window correctly --- mithril.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mithril.js b/mithril.js index e0281a9e..0a14570e 100644 --- a/mithril.js +++ b/mithril.js @@ -310,7 +310,7 @@ Mithril = m = new function app(window) { var element = arguments[0] var isInitialized = arguments[1] if (element.href.indexOf(modes[m.route.mode]) < 0) { - element.href = location.pathname + modes[m.route.mode] + element.pathname + element.href = window.location.pathname + modes[m.route.mode] + element.pathname } if (!isInitialized) { element.removeEventListener("click", routeUnobtrusive)