Skip to content

Commit

Permalink
codegen: Remove needless allocation
Browse files Browse the repository at this point in the history
  • Loading branch information
taiki-e committed Jun 21, 2024
1 parent 60a32c3 commit 926cd2a
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions tools/codegen/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -291,11 +291,8 @@ fn main() -> Result<()> {
Path::new(&url).file_name().unwrap().to_str().unwrap()
));
let response = download(&url)?;
let etag = response
.header("etag")
.expect("binary should have an etag")
.to_string()
.replace('\"', "");
let etag =
response.header("etag").expect("binary should have an etag").replace('\"', "");

if let Some(ManifestRef::Real(ref manifest)) = existing_manifest {
if let Some(entry) = manifest.download_info.get(&platform) {
Expand Down

0 comments on commit 926cd2a

Please sign in to comment.