Skip to content

Commit 53eef92

Browse files
committed
checksum_sha256: '-' when not present
it could be absent when data is carried from an another sponsorship, held before the checksum implementation.
1 parent 2df606e commit 53eef92

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/models/sponsorship_asset_file.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ def update_object_header
8686
head = s3_client.head_object(bucket: BUCKET, key: object_key, checksum_mode: :enabled)
8787
self.version_id = head.version_id if head.version_id != version_id
8888
self.last_modified_at = head.last_modified
89-
self.checksum_sha256 = head.checksum_sha256
89+
self.checksum_sha256 = head.checksum_sha256 || "-"
9090
self
9191
end
9292

0 commit comments

Comments
 (0)