mirror of
https://gitlab.com/news-flash/article_scraper.git
synced 2025-07-07 16:15:32 +02:00
fix save_html returning error even it succeeded
This commit is contained in:
parent
aa26e099df
commit
02356a51aa
1 changed files with 1 additions and 0 deletions
|
@ -30,6 +30,7 @@ impl Article {
|
||||||
let path = path.join(file_name);
|
let path = path.join(file_name);
|
||||||
let mut html_file = std::fs::File::create(&path).context(ScraperErrorKind::IO)?;
|
let mut html_file = std::fs::File::create(&path).context(ScraperErrorKind::IO)?;
|
||||||
html_file.write_all(html.as_bytes()).context(ScraperErrorKind::IO)?;
|
html_file.write_all(html.as_bytes()).context(ScraperErrorKind::IO)?;
|
||||||
|
return Ok(())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue