Fix clippy in registry_query.rs (#10652)

The toolkit check passes locally; I'm not sure what the difference is
there.

cc @fdncred who merged the previous PR
This commit is contained in:
Christopher Durham 2023-10-09 04:19:20 -04:00 committed by GitHub
parent ee4e0a933b
commit 2d72f892fe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -151,7 +151,7 @@ fn get_reg_hive(call: &Call) -> Result<RegKey, ShellError> {
Vec::new(),
));
}
let hive = flags.get(0).copied().unwrap_or("hkcu");
let hive = flags.first().copied().unwrap_or("hkcu");
let hkey = match hive {
"hkcr" => HKEY_CLASSES_ROOT,
"hkcu" => HKEY_CURRENT_USER,