Skip to content

Commit debf3d1

Browse files
committed
Fix error message for missing operation
1 parent 57d71e1 commit debf3d1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/execution/execute.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ function buildExecutionContext(
189189
}
190190
});
191191
if (!operation) {
192-
if (!operationName) {
192+
if (operationName) {
193193
throw new GraphQLError(`Unknown operation named "${operationName}".`);
194194
} else {
195195
throw new GraphQLError('Must provide an operation.');

0 commit comments

Comments
 (0)