format code
This commit is contained in:
parent
8f03cf4f17
commit
190f47d6ef
|
@ -186,7 +186,6 @@ pub fn genhtml_command(
|
|||
let file_path = std::path::PathBuf::from(genhtml_args.dest.as_str()).join("index.html");
|
||||
let html_index_file = std::fs::File::create(file_path);
|
||||
|
||||
|
||||
match html_index_file {
|
||||
Ok(mut file) => match file.write_all(html_content.as_bytes()) {
|
||||
Ok(_) => {}
|
||||
|
|
|
@ -165,7 +165,7 @@ pub fn process_command(
|
|||
for file in files.iter_mut() {
|
||||
add_replaygain_tags(file, process_args.force_replaygain)?;
|
||||
}
|
||||
|
||||
|
||||
return Ok(());
|
||||
} else {
|
||||
let jobs: Arc<Mutex<Vec<File>>> = Arc::new(Mutex::new(files));
|
||||
|
@ -180,7 +180,7 @@ pub fn process_command(
|
|||
let result = add_replaygain_tags(&job, process_args.force_replaygain);
|
||||
if let Err(err) = result {
|
||||
panic!("Error doing replaygain: {}", err)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -24,7 +24,8 @@ pub fn transcode_command(
|
|||
let transcode_config = transcode_preset_or_config(
|
||||
transcode_args.transcode_preset.as_ref(),
|
||||
transcode_args.transcode_config.as_ref(),
|
||||
).expect("transcode config error");
|
||||
)
|
||||
.expect("transcode config error");
|
||||
|
||||
println!("Transcoding");
|
||||
|
||||
|
|
|
@ -84,7 +84,8 @@ pub fn progress_monitor(
|
|||
let mut watcher = RecommendedWatcher::new(
|
||||
tx,
|
||||
notify::Config::default().with_poll_interval(Duration::from_millis(100)),
|
||||
).expect("could not watch for ffmpeg log progress status");
|
||||
)
|
||||
.expect("could not watch for ffmpeg log progress status");
|
||||
|
||||
watcher
|
||||
.watch(&file_path, RecursiveMode::NonRecursive)
|
||||
|
|
|
@ -50,7 +50,7 @@ pub fn transcode(
|
|||
|
||||
if let Some(sender) = &progress_sender {
|
||||
let result = progress_monitor(file.join_path_to(), sender);
|
||||
|
||||
|
||||
if let Ok(result) = result {
|
||||
progress_thread = Some(result.1);
|
||||
progress_file = Some(result.0.clone());
|
||||
|
|
Loading…
Reference in a new issue