From d682982a54bf1f1579c2e7cedd77def210dab77d Mon Sep 17 00:00:00 2001 From: Nolan Lawson Date: Fri, 23 Mar 2018 08:16:46 -0700 Subject: [PATCH] fix caching logic --- routes/_utils/isMobile.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routes/_utils/isMobile.js b/routes/_utils/isMobile.js index ecab10ec..b272a337 100644 --- a/routes/_utils/isMobile.js +++ b/routes/_utils/isMobile.js @@ -4,7 +4,7 @@ let cached export function isMobile () { - if (!cached) { + if (typeof cached === 'undefined') { cached = !!(process.browser && navigator.userAgent.match(/(iPhone|iPod|iPad|Android)/)) } return cached