Skip to content
This repository has been archived by the owner on Jul 25, 2022. It is now read-only.

Fix GUI clippy issues #1953

Merged
merged 1 commit into from
Jun 8, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion iml-gui/crate/src/components/action_dropdown/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ fn group_actions_by_label(xs: Vec<Arc<AvailableAction>>, cache: &ArcCache) -> Ac
let mut x = xs.into_iter().fold(BTreeMap::new(), |mut x, action| {
match cache.get_erased_record(&action.composite_id) {
Some(r) => {
let xs = x.entry(r.label().to_string()).or_insert_with(|| vec![]);
let xs = x.entry(r.label().to_string()).or_insert_with(Vec::new);

xs.push((action, r));
}
Expand Down
6 changes: 2 additions & 4 deletions iml-gui/crate/src/page/servers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -203,10 +203,8 @@ pub fn view(
.merge_attrs(class![C.text_center]),
table::td_view(date_view(sd, &x.boot_time)).merge_attrs(class![C.text_center]),
table::td_view(span![x.server_profile.ui_name]).merge_attrs(class![C.text_center]),
table::td_view(
div![lnet_by_server_view(x, cache, all_locks).unwrap_or_else(|| vec![])]
)
.merge_attrs(class![C.text_center]),
table::td_view(div![lnet_by_server_view(x, cache, all_locks).unwrap_or_else(Vec::new)])
.merge_attrs(class![C.text_center]),
td![
class![C.p_3, C.text_center],
action_dropdown::view(x.id, &row.dropdown, all_locks, session)
Expand Down