Skip to content

Commit 58993e6

Browse files
[6.x] Don't redirect to referrer when 2FA challenge is required (#13491)
1 parent 503c909 commit 58993e6

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

resources/js/pages/auth/Login.vue

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,13 @@ const submit = () => {
4141
processing.value = true;
4242
errors.value = {};
4343
},
44-
onSuccess: () => window.location.href = props.referer,
44+
onSuccess: (page) => {
45+
if (page.component === 'auth/two-factor/Challenge') {
46+
return;
47+
}
48+
49+
window.location.href = props.referer;
50+
},
4551
onError: () => processing.value = false
4652
});
4753
}

0 commit comments

Comments
 (0)