diff options
Diffstat (limited to 'crates/shirabe/src/downloader/gzip_downloader.rs')
| -rw-r--r-- | crates/shirabe/src/downloader/gzip_downloader.rs | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/crates/shirabe/src/downloader/gzip_downloader.rs b/crates/shirabe/src/downloader/gzip_downloader.rs index 70b9f7bb..297cbc11 100644 --- a/crates/shirabe/src/downloader/gzip_downloader.rs +++ b/crates/shirabe/src/downloader/gzip_downloader.rs @@ -84,15 +84,12 @@ impl ArchiveDownloader for GzipDownloader { parse_url( &strtr(&package.get_dist_url().unwrap_or_default(), "\\", "/"), PHP_URL_PATH, - ), + ) + .as_string() + .unwrap_or(""), PATHINFO_FILENAME, ); - let target_filepath = format!( - "{}{}{}", - path, - DIRECTORY_SEPARATOR, - filename.as_string().unwrap_or_default() - ); + let target_filepath = format!("{}{}{}", path, DIRECTORY_SEPARATOR, filename); if !Platform::is_windows() { let command = vec