Skip to content

Commit

Permalink
refactor (#450)
Browse files Browse the repository at this point in the history
Don't use `static` unless it's really needed
  • Loading branch information
Byron committed Nov 2, 2022
1 parent f409e4a commit 4dd67db
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gitoxide-core/src/repository/remote.rs
Expand Up @@ -280,8 +280,8 @@ mod refs_impl {
object,
} => write!(&mut out, "{} {} symref-target:{}", object, path, target).map(|_| object.as_ref()),
fetch::Ref::Unborn { full_ref_name, target } => {
static NULL: git::hash::ObjectId = git::hash::ObjectId::null(git::hash::Kind::Sha1);
write!(&mut out, "unborn {} symref-target:{}", full_ref_name, target).map(|_| NULL.as_ref())
let null = git::hash::ObjectId::null(git::hash::Kind::Sha1);
write!(&mut out, "unborn {} symref-target:{}", full_ref_name, target).map(|_| null.as_ref())
}
}
}
Expand Down

0 comments on commit 4dd67db

Please sign in to comment.