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

adding statuslist conversion #280

Merged
merged 2 commits into from
Jan 31, 2023
Merged

adding statuslist conversion #280

merged 2 commits into from
Jan 31, 2023

Conversation

nitro-neal
Copy link
Contributor

This change allows us to use a StatusList2021Entry or a map[string]interface as our credStatus object.

@@ -303,3 +303,25 @@ func ValidateCredentialInStatusList(credentialToValidate credential.VerifiableCr
}
return false, nil
}

func ToStatusList2021Entry(credStatus interface{}) (*StatusList2021Entry, bool) {
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
func ToStatusList2021Entry(credStatus interface{}) (*StatusList2021Entry, bool) {
func toStatusList2021Entry(credStatus interface{}) (*StatusList2021Entry, bool) {

@@ -252,7 +252,7 @@ func bitstringExpansion(compressedBitstring string) ([]string, error) {
// NOTE: this method does perform credential signature/proof block verification
func ValidateCredentialInStatusList(credentialToValidate credential.VerifiableCredential, statusCredential credential.VerifiableCredential) (bool, error) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you update the godoc?

@codecov-commenter
Copy link

Codecov Report

Merging #280 (a6bfcde) into main (1c62321) will increase coverage by 0.09%.
The diff coverage is 84.21%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #280      +/-   ##
==========================================
+ Coverage   60.34%   60.43%   +0.09%     
==========================================
  Files          40       40              
  Lines        4440     4458      +18     
==========================================
+ Hits         2679     2694      +15     
- Misses       1328     1330       +2     
- Partials      433      434       +1     
Impacted Files Coverage Δ
credential/status/statuslist2021.go 64.65% <84.21%> (+1.71%) ⬆️

@nitro-neal nitro-neal merged commit 6519a59 into main Jan 31, 2023
@nitro-neal nitro-neal deleted the adding-statuslist-convert branch January 31, 2023 19:30
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.

None yet

4 participants