diff --git a/src/modules/git.rs b/src/modules/git.rs index 439fc9c..732df5f 100644 --- a/src/modules/git.rs +++ b/src/modules/git.rs @@ -50,10 +50,10 @@ pub fn segment(segment: &mut Segment, args: &[&str]) { for status in statuses.iter() { // dirty segment.background = if args.is_empty() { - "yellow".to_owned() + "yellow" } else { - args[0].to_owned() - }; + args[0] + }.to_owned(); let status = status.status(); if modified.is_empty() && status.is_wt_new()