Skip to content

Commit

Permalink
fix/Popup for changing duplicate username is bugged/2013 (#2144)
Browse files Browse the repository at this point in the history
* fix: comment logic in saveUserCsr

* fix: component and add test
  • Loading branch information
Kacper-RF authored Dec 6, 2023
1 parent 7e6a034 commit f380384
Show file tree
Hide file tree
Showing 2 changed files with 655 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,12 @@ export const UsernameRegistration: FC<UsernameRegistrationProps> = ({
}
}, [usernameRegistered])

useEffect(() => {
if (variant === UsernameVariant.TAKEN && loading && userName === '') {
setLoading(false)
}
}, [variant, loading, userName])

const icon = appImages.icon_warning

return (
Expand Down Expand Up @@ -149,7 +155,7 @@ export const UsernameRegistration: FC<UsernameRegistrationProps> = ({

<View style={{ marginTop: 20 }}>
<Button
disabled={Boolean(inputError)}
disabled={Boolean(inputError) || loading}
onPress={onPress}
title={'Continue'}
loading={loading}
Expand Down
Loading

0 comments on commit f380384

Please sign in to comment.