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

Fix stream directive validation error message #4044

Merged
Merged
Show file tree
Hide file tree
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 @@ -241,7 +241,7 @@ describe('Validate: Defer/Stream directive on valid operations', () => {
`).toDeepEqual([
{
message:
'Stream directive not supported on subscription operations. Disable `@defer` by setting the `if` argument to `false`.',
'Stream directive not supported on subscription operations. Disable `@stream` by setting the `if` argument to `false`.',
locations: [{ line: 4, column: 20 }],
},
]);
Expand All @@ -259,7 +259,7 @@ describe('Validate: Defer/Stream directive on valid operations', () => {
`).toDeepEqual([
{
message:
'Stream directive not supported on subscription operations. Disable `@defer` by setting the `if` argument to `false`.',
'Stream directive not supported on subscription operations. Disable `@stream` by setting the `if` argument to `false`.',
locations: [{ line: 8, column: 18 }],
},
]);
Expand Down Expand Up @@ -301,7 +301,7 @@ describe('Validate: Defer/Stream directive on valid operations', () => {
`).toDeepEqual([
{
message:
'Stream directive not supported on subscription operations. Disable `@defer` by setting the `if` argument to `false`.',
'Stream directive not supported on subscription operations. Disable `@stream` by setting the `if` argument to `false`.',
locations: [{ line: 15, column: 18 }],
},
]);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ export function DeferStreamDirectiveOnValidOperationsRule(
if (!ifArgumentCanBeFalse(node)) {
context.reportError(
new GraphQLError(
'Stream directive not supported on subscription operations. Disable `@defer` by setting the `if` argument to `false`.',
'Stream directive not supported on subscription operations. Disable `@stream` by setting the `if` argument to `false`.',
{ nodes: node },
),
);
Expand Down
Loading