Skip to content

Commit

Permalink
rebase and cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
austin-denoble committed Nov 7, 2023
1 parent 7b819ac commit c655eae
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/control/__tests__/createIndex.validation.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ describe('createIndex argument validations', () => {

expect(toThrow).rejects.toThrowError(PineconeArgumentError);
expect(toThrow).rejects.toThrowError(
"The argument to createIndex had type errors: property 'cloud' is a constant which must be equal to one of: 'gcp', 'aws', 'azure'."
"The argument to createIndex had type errors: property 'cloud' must be equal to one of: 'gcp', 'aws', 'azure'."
);
});

Expand All @@ -196,7 +196,7 @@ describe('createIndex argument validations', () => {

expect(toThrow).rejects.toThrowError(PineconeArgumentError);
expect(toThrow).rejects.toThrowError(
"The argument to createIndex had type errors: property 'cloud' is a constant which must be equal to one of: 'gcp', 'aws', 'azure'."
"The argument to createIndex had type errors: property 'cloud' must be equal to one of: 'gcp', 'aws', 'azure'."
);
});

Expand Down
2 changes: 1 addition & 1 deletion src/validator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ const typeErrors = (
const constValueErrors = propErrorGroups[property];

typeErrorsList.push(
`property '${property}' is a constant which must be equal to one of: ` +
`property '${property}' must be equal to one of: ` +
Object.values(constValueErrors)
.map((group) => `'${group.params.allowedValue}'`)
.join(', ')
Expand Down

0 comments on commit c655eae

Please sign in to comment.