fix: username fallback when there's no full name

This commit is contained in:
Jonathan Capps 2025-04-18 17:07:42 +01:00 committed by Michael Murphy
parent b340489946
commit 44ad521ab0

View file

@ -745,7 +745,11 @@ fn user_list() -> Section<crate::pages::Message> {
.on_input(move |name| Message::Edit(idx, EditorField::FullName, name))
.on_submit(move |_| Message::ApplyEdit(idx, EditorField::FullName));
let fullname_text = text::body(&user.full_name);
let fullname_text = text::body(if &user.full_name != "" {
&user.full_name
} else {
&user.username
});
let account_type = text::caption(if user.is_admin {
&descriptions[user_type_admin]