Skip to content

Commit

Permalink
Add store credential functionality in issuer.go
Browse files Browse the repository at this point in the history
Added code to store the issued credential in vcrStore within the issuer.go file.
  • Loading branch information
rolandgroen committed Feb 12, 2024
1 parent 0f3c382 commit 66ff290
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions vcr/issuer/issuer.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,10 @@ func (i issuer) Issue(ctx context.Context, template vc.VerifiableCredential, opt
return nil, fmt.Errorf("unable to store the issued credential: %w", err)
}

if err = i.vcrStore.StoreCredential(*createdVC, nil); err != nil {
return nil, fmt.Errorf("unable to store the issued credential: %w", err)
}

if options.Publish {
// Try to issue over OpenID4VCI if it's enabled and if the credential is not public
// (public credentials are always published on the network).
Expand Down

0 comments on commit 66ff290

Please sign in to comment.