Skip to content

Commit

Permalink
Merge pull request #197 from miabbott/clippy
Browse files Browse the repository at this point in the history
lib: apply clippy fix for needless borrowing
  • Loading branch information
cgwalters authored Nov 10, 2023
2 parents 282eff6 + 52e568f commit 0088fda
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ async fn edit(opts: EditOpts) -> Result<()> {
let (booted_deployment, _deployments, host) =
crate::status::get_status_require_booted(sysroot)?;
let new_host: Host = if let Some(filename) = opts.filename {
let mut r = std::io::BufReader::new(std::fs::File::open(&filename)?);
let mut r = std::io::BufReader::new(std::fs::File::open(filename)?);
serde_yaml::from_reader(&mut r)?
} else {
let tmpf = tempfile::NamedTempFile::new()?;
Expand Down
2 changes: 1 addition & 1 deletion lib/src/install.rs
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,7 @@ async fn verify_target_fetch(imgref: &ostree_container::OstreeImageReference) ->

tracing::trace!("Verifying fetch for {imgref}");
let mut imp =
ostree_container::store::ImageImporter::new(&tmprepo, imgref, Default::default()).await?;
ostree_container::store::ImageImporter::new(tmprepo, imgref, Default::default()).await?;
use ostree_container::store::PrepareResult;
let prep = match imp.prepare().await? {
// SAFETY: It's impossible that the image was already fetched into this newly created temporary repository
Expand Down

0 comments on commit 0088fda

Please sign in to comment.