Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ba401e1

Browse files
committed
Unify wording in error messages.
Before this change there was: - There can be only one argument named ... - There can be only one input field named ... - There can be only one variable named ... - There can only be one fragment named ... - There can only be one operation named ... Now the last two match the others.
1 parent 2c8d565 commit ba401e1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/validation/rules/UniqueFragmentNames.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import { GraphQLError } from '../../error';
1313

1414

1515
export function duplicateFragmentNameMessage(fragName: string): string {
16-
return `There can only be one fragment named "${fragName}".`;
16+
return `There can be only one fragment named "${fragName}".`;
1717
}
1818

1919
/**

src/validation/rules/UniqueOperationNames.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import { GraphQLError } from '../../error';
1313

1414

1515
export function duplicateOperationNameMessage(operationName: string): string {
16-
return `There can only be one operation named "${operationName}".`;
16+
return `There can be only one operation named "${operationName}".`;
1717
}
1818

1919
/**

0 commit comments

Comments
 (0)