Skip to content

Commit 3e3202e

Browse files
minhho89cweitat
andauthored
8689 permanent sign in (#8938)
* Add Paragraph field, text area * fix setSessionCookie * Update login-form.js --------- Co-authored-by: cweitat <[email protected]>
1 parent 076c3c6 commit 3e3202e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

app/components/forms/login-form.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,9 @@ export default class LoginForm extends Component.extend(FormMixin) {
2121
rememberMe = false;
2222

2323
set setSessionCookie(rememberMe) {
24-
const expirationTime = rememberMe ? (365 * 24 * 60 * 60) : (1 * 24 * 60 * 60);
25-
this.set('session.store.cookieExpirationTime', expirationTime);
24+
const SECONDS_IN_DAY = 86400;
25+
const expirationTime = rememberMe ? (365 * SECONDS_IN_DAY) : (1 * SECONDS_IN_DAY);
26+
this.session.store.cookieExpirationTime = expirationTime;
2627
}
2728

2829
getValidationRules() {

0 commit comments

Comments
 (0)