main::save_page_img: Take a Path
, not PathBuf
This commit is contained in:
parent
cf3c01fef8
commit
f7d6f861b5
@ -180,7 +180,7 @@ fn save_to_file<P: AsRef<Path>, T: Serialize, F: Formatter>(
|
||||
pub async fn save_page_img(
|
||||
page: &freefall::Page,
|
||||
bytes: Bytes,
|
||||
target_dir: &PathBuf,
|
||||
target_dir: &Path,
|
||||
) -> Result<PathBuf, anyhow::Error> {
|
||||
if !page.img_url.ends_with("png") {
|
||||
return Err(anyhow!(
|
||||
|
Loading…
Reference in New Issue
Block a user