diff options
author | Wu Cheng-Han | 2016-07-30 10:59:51 +0800 |
---|---|---|
committer | Wu Cheng-Han | 2016-07-30 10:59:51 +0800 |
commit | b8ff9112ef1556e6996b2f64ad6df559b6f2c2fb (patch) | |
tree | 6a55d860e9bfe3bb9fd59f0cba8a42763a0b2a72 /public | |
parent | 423dccae0e4096aa1b84ce5c9c1cfa9624f0f841 (diff) |
Fix cookies might not in boolean type cause page refresh loop
Diffstat (limited to '')
-rw-r--r-- | public/js/common.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/public/js/common.js b/public/js/common.js index 5e9456bd..cfde462c 100644 --- a/public/js/common.js +++ b/public/js/common.js @@ -53,7 +53,8 @@ function checkLoginStateChanged() { } function getLoginState() { - return Cookies.get('loginstate') === "true"; + var state = Cookies.get('loginstate'); + return state === "true" || state === true; } function getUserId() { |