fix: actually save basalt repo and path in profile editor

This commit is contained in:
Gabriele Musco 2024-05-13 14:36:09 +02:00
commit cd731d2e8e
No known key found for this signature in database
GPG key ID: 1068D795C80E51DE

View file

@ -318,7 +318,7 @@ impl SimpleComponent for ProfileEditor {
model.profile.borrow().features.basalt.repo.clone().unwrap_or_default().as_str(),
clone!(@strong prof => move |row| {
let n_val = row.text().to_string();
prof.borrow_mut().features.basalt.repo = n_val.is_empty().then_some(n_val);
prof.borrow_mut().features.basalt.repo = (!n_val.is_empty()).then_some(n_val);
})
),
add: &entry_row(
@ -326,7 +326,7 @@ impl SimpleComponent for ProfileEditor {
model.profile.borrow().features.basalt.branch.clone().unwrap_or_default().as_str(),
clone!(@strong prof => move |row| {
let n_val = row.text().to_string();
prof.borrow_mut().features.basalt.branch = n_val.is_empty().then_some(n_val);
prof.borrow_mut().features.basalt.branch = (!n_val.is_empty()).then_some(n_val);
})
),
},