mirror of
https://github.com/hyzendust/hyzendust.github.io.git
synced 2026-07-01 15:32:17 +02:00
Fix: services pagination. Fix: login/signup auto-redirect to homepage if already logged in
This commit is contained in:
@@ -183,9 +183,6 @@
|
||||
'auth-message auth-message--success';
|
||||
document.getElementById('auth-message').style.display = 'block';
|
||||
document.getElementById('signup-form').style.display = 'none';
|
||||
setTimeout(function () {
|
||||
window.location.href = '/';
|
||||
}, 1500);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -195,7 +192,6 @@
|
||||
sessionStorage.getItem('f4_login_next') ||
|
||||
'';
|
||||
|
||||
// Save referrer as next-page if not already set and referrer is on this site
|
||||
if (!_signupNext && document.referrer) {
|
||||
try {
|
||||
var _refUrl = new URL(document.referrer);
|
||||
@@ -394,11 +390,11 @@
|
||||
if (data.success) {
|
||||
showMsg('Account created! Redirecting to login\u2026', 'success');
|
||||
setTimeout(function () {
|
||||
window.location.href =
|
||||
_signupNext && _signupNext.startsWith('/')
|
||||
? '/login/?next=' + encodeURIComponent(_signupNext)
|
||||
: '/login/';
|
||||
window.location.href = '/login/';
|
||||
var _loginUrl = '/login/';
|
||||
if (_signupNext && _signupNext.startsWith('/')) {
|
||||
_loginUrl = '/login/?next=' + encodeURIComponent(_signupNext);
|
||||
}
|
||||
window.location.href = _loginUrl;
|
||||
}, 1800);
|
||||
} else {
|
||||
showMsg(data.message || 'Sign-up failed. Please try again.', 'error');
|
||||
|
||||
Reference in New Issue
Block a user