Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace user's nickname with name and last name #295

Merged

Conversation

cristhianescobar
Copy link
Collaborator

No description provided.

)
)
Email(
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will make a ticket to create an actual input component for non email fields. For now we will keep this 😓

@@ -62,3 +62,11 @@ data class User(
val newPassword: String? = null,
val confirmPassword: String? = null
)

fun User.fullName(): String? {
return if(!firstName.isNullOrBlank() && !lastName.isNullOrBlank()) "$firstName $lastName" else null
Copy link
Contributor

@wlara wlara Jul 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some users may have set only one of first name or last name. In the server we use this to support all possibilities when building fullName:

"${firstName.orEmpty().trim()} ${lastName.orEmpty().trim()}".trim()

@cristhianescobar cristhianescobar merged commit daaee1b into development Jul 22, 2024
1 of 2 checks passed
@cristhianescobar cristhianescobar deleted the cristhian/remove-replace-nickname-with-user-name branch July 22, 2024 04:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants