Skip to content

Commit e38de0f

Browse files
committed
refactor(rm): format prompt_yes! macro calls for readability
Break long prompt_yes! macro invocations into multiple lines in the handle_writable_directory function to improve code readability and adhere to formatting standards. No functional changes.
1 parent d8f7f0e commit e38de0f

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

src/uu/rm/src/rm.rs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -915,7 +915,10 @@ fn handle_writable_directory(path: &Path, options: &Options, metadata: &Metadata
915915
)
916916
),
917917
(_, _, InteractiveMode::Always) => {
918-
prompt_yes!("{}", translate!("rm-prompt-remove-directory", "path" => path.quote()))
918+
prompt_yes!(
919+
"{}",
920+
translate!("rm-prompt-remove-directory", "path" => path.quote())
921+
)
919922
}
920923
(_, _, _) => true,
921924
}
@@ -926,7 +929,10 @@ fn handle_writable_directory(path: &Path, options: &Options, metadata: &Metadata
926929
#[cfg(not(unix))]
927930
fn handle_writable_directory(path: &Path, options: &Options, _metadata: &Metadata) -> bool {
928931
if options.interactive == InteractiveMode::Always {
929-
prompt_yes!("{}", translate!("rm-prompt-remove-directory", "path" => path.quote()))
932+
prompt_yes!(
933+
"{}",
934+
translate!("rm-prompt-remove-directory", "path" => path.quote())
935+
)
930936
} else {
931937
true
932938
}

0 commit comments

Comments
 (0)