Skip to content

Commit

Permalink
fix: hide split char on empty
Browse files Browse the repository at this point in the history
fix #38
  • Loading branch information
roosta committed Feb 29, 2024
1 parent cbd1a5d commit f788100
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ pub fn update_tree(
let mut new: String = String::from(initial);

// if we do split on colon we need to insert a new one, cause it gets split out
if split_at == ':' && !initial.is_empty() {
if split_at == ':' && !initial.is_empty() && !titles.is_empty() {
new.push(':');
}
// Push new window titles to new string
Expand Down

0 comments on commit f788100

Please sign in to comment.