Fix option not derefing

This commit is contained in:
Edward Shen 2021-10-30 18:39:40 -07:00
parent bb35f710b2
commit a5b105f486
Signed by: edward
GPG key ID: 19182661E818369F

View file

@ -140,7 +140,7 @@ fn handle_download(mut url: ParsedUrl) -> Result<()> {
password = Some(input); password = Some(input);
} }
open_in_place(&mut data, &url.decryption_key, &password)?; open_in_place(&mut data, &url.decryption_key, password.as_deref())?;
if atty::is(Stream::Stdout) { if atty::is(Stream::Stdout) {
if let Ok(data) = String::from_utf8(data) { if let Ok(data) = String::from_utf8(data) {