From 0f9da68d358e20481d37878e9a6e0b3fdcd54fb2 Mon Sep 17 00:00:00 2001 From: Vesa Luusua Date: Thu, 12 Jan 2017 14:41:19 +0200 Subject: [PATCH] Call functions from window more explicitly --- src/Routes.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Routes.js b/src/Routes.js index 1c300597..4e2ce7b9 100644 --- a/src/Routes.js +++ b/src/Routes.js @@ -29,16 +29,17 @@ const RedirectLandingPage = () => ; // Fake authentication module // An example from react-router v4 repository +// This will be replaced once we have redux store and sdk export const fakeAuth = { isAuthenticated: false, authenticate(cb) { this.isAuthenticated = true; - setTimeout(cb, 100); // fake async + window.setTimeout(cb, 100); // fake async }, signout(cb) { this.isAuthenticated = false; cb(); - setTimeout(cb, 100); // weird bug if async? + window.setTimeout(cb, 100); // weird bug if async? } };