return false if registry open fails

pull/2483/head
Lucas Fernandes Nogueira 4 months ago committed by GitHub
parent 35b15662be
commit c3bd493a4f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -408,7 +408,10 @@ mod imp {
#[cfg(windows)]
{
let protocol = _protocol.as_ref();
let cmd_reg = CLASSES_ROOT.open(format!("{protocol}\\shell\\open\\command"))?;
let Ok(cmd_reg) = CLASSES_ROOT.open(format!("{protocol}\\shell\\open\\command"))
else {
return Ok(false);
};
let registered_cmd = cmd_reg.get_string("")?;

Loading…
Cancel
Save