diff --git a/packages/frontend/src/components/MkSignin.vue b/packages/frontend/src/components/MkSignin.vue index 58a666de6f..82e0df8a01 100644 --- a/packages/frontend/src/components/MkSignin.vue +++ b/packages/frontend/src/components/MkSignin.vue @@ -117,14 +117,19 @@ const props = withDefaults(defineProps<{ }); function onUsernameChange(): void { + const usernameRequested = username.value; misskeyApi('users/show', { - username: username.value, + username: usernameRequested, }).then(userResponse => { - user.value = userResponse; - usePasswordLessLogin.value = userResponse.usePasswordLessLogin; + if (userResponse.username === username.value) { + user.value = userResponse; + usePasswordLessLogin.value = userResponse.usePasswordLessLogin; + } }, () => { - user.value = null; - usePasswordLessLogin.value = true; + if (usernameRequested === username.value) { + user.value = null; + usePasswordLessLogin.value = true; + } }); }