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

Revert "[ES-504] Internal credential object considered for forming the final …" #10

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,6 @@ public class SunbirdRCVCIssuancePlugin implements VCIssuancePlugin {

private static final String STATIC_VALUE_MAP_ISSUER_ID = "static-value-map.issuerId";

private static final String CREDENTIAL_OBJECT_KEY = "credential";

@Autowired
Environment env;

Expand Down Expand Up @@ -146,7 +144,7 @@ public VCResult<JsonLDObject> getVerifiableCredentialWithLinkedDataProof(VCReque
Map<String,Object> vcResponseMap =sendCredentialIssueRequest(credentialRequestMap);

VCResult vcResult = new VCResult();
JsonLDObject vcJsonLdObject = JsonLDObject.fromJsonObject(vcResponseMap.get(CREDENTIAL_OBJECT_KEY));
JsonLDObject vcJsonLdObject = JsonLDObject.fromJsonObject(vcResponseMap);
vcResult.setCredential(vcJsonLdObject);
vcResult.setFormat(LINKED_DATA_PROOF_VC_FORMAT);
return vcResult;
Expand Down Expand Up @@ -275,4 +273,11 @@ private void validateContextUrl(Template template,List<String> vcRequestContextL
throw new VCIExchangeException(ErrorConstants.VCI_EXCHANGE_FAILED);
}
}

private static Date calculateNowPlus30Days() {
// Implement your logic to calculate current date + 30 days
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.DAY_OF_MONTH, 30);
return calendar.getTime();
}
}