Skip to content
Snippets Groups Projects
Unverified Commit db73cd20 authored by Markus Reiter's avatar Markus Reiter Committed by GitHub
Browse files

Merge pull request #9496 from reitermarkus/fix-curl_http_content_headers_and_checksum

Fix `curl_http_content_headers_and_checksum`.
parents b3236ced a5dbba5b
No related branches found
No related tags found
No related merge requests found
......@@ -249,7 +249,7 @@ module Utils
final_url = location.chomp if location
end
output_hash = Digest::SHA256.file(file.path) if hash_needed
file_hash = Digest::SHA256.file(file.path) if hash_needed
final_url ||= url
......@@ -260,8 +260,8 @@ module Utils
etag: headers[%r{ETag: ([wW]/)?"(([^"]|\\")*)"}, 2],
content_length: headers[/Content-Length: (\d+)/, 1],
headers: headers,
file_hash: output_hash,
file: output,
file_hash: file_hash,
file: File.read(file.path),
}
ensure
file.unlink
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment