modify todo

cli-redesign
Avril 4 years ago
parent ed9057e6e0
commit a1bbaa3014
Signed by: flanchan
GPG Key ID: 284488987C31F630

@ -14,7 +14,7 @@ mod tasklist;
#[macro_use]
mod progress;
//TODO: Create a module for temp files, pass the temp file to `perform` and do the regex fixing after `perform`
//TODO: Create a module for temp files, pass the temp file to `perform` and do the base64 fixing after `perform`
/// Download a loli async
pub async fn perform(url: impl AsRef<str>, path: impl AsRef<Path>, mut progress: progress::CommandSender) -> Result<(), error::Error>
@ -84,7 +84,7 @@ pub async fn work(conf: config::Config) -> Result<(), Box<dyn std::error::Error>
//println!("Starting download ({})...", url);
prog.println(format!("Starting download ({})...", url)).await.expect("fatal");
let path = match path {
config::OutputType::File(file) => file,
config::OutputType::File(file) => file, //TODO: Download to temp file, memmap to str slice and then base64 decode. Also, determine if we need .png or .jpg from header.
config::OutputType::Directory(dir) => {
//TODO: Implement downloading to temp and renaming to hash
unimplemented!();

Loading…
Cancel
Save