Update to extend login info cookies to 365 days to reduce reductant page refresh

This commit is contained in:
Cheng-Han, Wu 2016-06-26 23:37:59 +08:00
parent 65b91e0b66
commit 83d8142045
1 changed files with 2 additions and 2 deletions

View File

@ -28,11 +28,11 @@ function resetCheckAuth() {
function setLoginState(bool, id) {
Cookies.set('loginstate', bool, {
expires: 14
expires: 365
});
if (id) {
Cookies.set('userid', id, {
expires: 14
expires: 365
});
} else {
Cookies.remove('userid');