Skip to content

Commit

Permalink
adds back quotes around named values in error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
kezike committed Dec 13, 2023
1 parent 79cbf41 commit 7b0b213
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/credential-status-manager-base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ export abstract class BaseCredentialStatusManager {
throw new BadRequestError({
message:
'"credentialStatus" must be one of the following values: ' +
`${Object.values(CredentialState).join(', ')}.`
`${Object.values(CredentialState).map(s => `"${s}"`).join(', ')}.`
});
}
const statusCredentialUrlBase = this.getStatusCredentialUrlBase();
Expand Down
2 changes: 1 addition & 1 deletion src/credential-status-manager-github.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export class GitHubCredentialStatusManager extends BaseCredentialStatusManager {
message:
'You have neglected to set the following required options for the ' +
'GitHub credential status manager: ' +
`${missingOptions.join(', ')}.`
`${missingOptions.map(o => `"${o}"`).join(', ')}.`
});
}

Expand Down
2 changes: 1 addition & 1 deletion src/credential-status-manager-gitlab.ts
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ export class GitLabCredentialStatusManager extends BaseCredentialStatusManager {
message:
'You have neglected to set the following required options for the ' +
'GitLab credential status manager: ' +
`${missingOptions.join(', ')}.`
`${missingOptions.map(o => `"${o}"`).join(', ')}.`
});
}

Expand Down
2 changes: 1 addition & 1 deletion src/credential-status-manager-index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export async function createStatusManager(options: CredentialStatusManagerOption
throw new BadRequestError({
message:
'"service" must be one of the following values: ' +
`${Object.values(CredentialStatusManagerService).join(', ')}.`
`${Object.values(CredentialStatusManagerService).map(s => `"${s}"`).join(', ')}.`
});
}

Expand Down
2 changes: 1 addition & 1 deletion src/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ export async function getSigningMaterial({
throw new BadRequestError({
message:
'"didMethod" must be one of the following values: ' +
`${Object.values(DidMethod).join(', ')}.`
`${Object.values(DidMethod).map(m => `"${m}"`).join(', ')}.`
});
}
const issuerDid = didDocument.id;
Expand Down

0 comments on commit 7b0b213

Please sign in to comment.