Skip to content

Commit

Permalink
fix: update to vc-data-model v1.0
Browse files Browse the repository at this point in the history
issued -> issuanceDate
claim -> credentialSubject

jolocom/jolocom-lib#393
  • Loading branch information
PeterTheOne committed Aug 24, 2020
1 parent 7e74be7 commit f5da46f
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 10 deletions.
3 changes: 1 addition & 2 deletions dist/lib/contracts.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { IVaultedKeyProvider } from './vaultedKeyProvider';
interface ContractsGatewayInfo {
name: string;
chainId: number;
Expand All @@ -9,7 +8,7 @@ interface AddressInfo {
balance: number;
}
export interface IContractsAdapter {
assembleTxFromInteractionToken: (requestToken: ITransactionEncodable, from: string, nonce: number, vault: IVaultedKeyProvider, pass: string) => string;
assembleTxFromInteractionToken: (requestToken: ITransactionEncodable, from: string, nonce: number, vault: any, pass: string) => string;
}
export interface IContractsGateway {
getNetworkInfo: () => ContractsGatewayInfo | {};
Expand Down
2 changes: 1 addition & 1 deletion dist/lib/credential.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@ export interface IClaimSection {
export interface ICredentialAttrs extends JsonLdObject {
type: string[];
name?: string;
claim: ClaimEntry;
credentialSubject: ClaimEntry;
}
export {};
6 changes: 3 additions & 3 deletions dist/lib/signedCredential.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ import { SignedJsonLdObject } from './linkedData';
export interface ISignedCredentialAttrs extends SignedJsonLdObject, ICredentialAttrs {
id: string;
issuer: string;
issued: string;
issuanceDate: string;
expires?: string;
claim: IClaimSection;
credentialSubject: IClaimSection;
}
export interface ISignedCredCreationArgs<T extends BaseMetadata> {
metadata: T;
claim: T['claimInterface'];
credentialSubject: T['claimInterface'];
subject: string;
}
export interface IKeyMetadata {
Expand Down
2 changes: 1 addition & 1 deletion lib/credential.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@ export interface IClaimSection {
export interface ICredentialAttrs extends JsonLdObject {
type: string[]
name?: string
claim: ClaimEntry
credentialSubject: ClaimEntry
}
6 changes: 3 additions & 3 deletions lib/signedCredential.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ import { SignedJsonLdObject } from './linkedData'
export interface ISignedCredentialAttrs extends SignedJsonLdObject, ICredentialAttrs {
id: string
issuer: string
issued: string
issuanceDate: string
expires?: string
claim: IClaimSection
credentialSubject: IClaimSection
}

/* Allows for neat claim autocompletion based on metadata type */
export interface ISignedCredCreationArgs<T extends BaseMetadata> {
metadata: T
claim: T['claimInterface']
credentialSubject: T['claimInterface']
subject: string
}

Expand Down

0 comments on commit f5da46f

Please sign in to comment.