Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: change SignedBodyValue enum to allow precomputed sha256 hash #271

Merged
merged 3 commits into from
Jun 25, 2024

Conversation

dayaffe
Copy link
Contributor

@dayaffe dayaffe commented Jun 25, 2024

Issue #:
#1331

Dependent PRs to consume updated crt version:

Description of changes:

  • Convert SignedBodyValue from enum: String to enum: CustomStringConvertible, Equatable to allow for pre-calculated SHA256 as intended

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Copy link
Contributor

@waahm7 waahm7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix & Ship

}
}

public static func ==(lhs: SignedBodyValue, rhs: SignedBodyValue) -> Bool {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

trivial: lint warnings

return ""
case .emptySha256:
return "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"
case .sha256(let hash):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
case .sha256(let hash):
case .precomputedSha256(let value):

@dayaffe dayaffe merged commit 9d6d175 into main Jun 25, 2024
25 checks passed
@dayaffe dayaffe deleted the day/enable-s3-tests branch June 25, 2024 19:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants