Rewrite untar to take a visitor & simplify

signature of `download_and_extract_with_filter`

Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
Jiahao XU 2022-06-11 20:31:46 +10:00
parent 5a43ee2681
commit 90a96cabc9
No known key found for this signature in database
GPG key ID: 591C0B03040416D6
4 changed files with 64 additions and 38 deletions

View file

@ -92,7 +92,7 @@ pub async fn download_and_extract_with_filter<
url: Url,
fmt: TarBasedFmt,
path: P,
filter: Option<Filter>,
filter: Filter,
) -> Result<(), BinstallError> {
debug!("Downloading from: '{url}'");