File tree 2 files changed +18
-22
lines changed
2 files changed +18
-22
lines changed Original file line number Diff line number Diff line change @@ -149,20 +149,18 @@ export function execute(
149
149
fieldResolver
150
150
) {
151
151
// Extract arguments from object args if provided.
152
- const args = arguments . length === 1 ? argsOrSchema : undefined ;
153
- const schema = args ? args . schema : argsOrSchema ;
154
- return args ?
152
+ return arguments . length === 1 ?
155
153
executeImpl (
156
- schema ,
157
- args . document ,
158
- args . rootValue ,
159
- args . contextValue ,
160
- args . variableValues ,
161
- args . operationName ,
162
- args . fieldResolver
154
+ argsOrSchema . schema ,
155
+ argsOrSchema . document ,
156
+ argsOrSchema . rootValue ,
157
+ argsOrSchema . contextValue ,
158
+ argsOrSchema . variableValues ,
159
+ argsOrSchema . operationName ,
160
+ argsOrSchema . fieldResolver
163
161
) :
164
162
executeImpl (
165
- schema ,
163
+ argsOrSchema ,
166
164
document ,
167
165
rootValue ,
168
166
contextValue ,
Original file line number Diff line number Diff line change @@ -75,20 +75,18 @@ export function graphql(
75
75
fieldResolver
76
76
) {
77
77
// Extract arguments from object args if provided.
78
- const args = arguments . length === 1 ? argsOrSchema : undefined ;
79
- const schema = args ? args . schema : argsOrSchema ;
80
- return args ?
78
+ return arguments . length === 1 ?
81
79
graphqlImpl (
82
- schema ,
83
- args . source ,
84
- args . rootValue ,
85
- args . contextValue ,
86
- args . variableValues ,
87
- args . operationName ,
88
- args . fieldResolver
80
+ argsOrSchema . schema ,
81
+ argsOrSchema . source ,
82
+ argsOrSchema . rootValue ,
83
+ argsOrSchema . contextValue ,
84
+ argsOrSchema . variableValues ,
85
+ argsOrSchema . operationName ,
86
+ argsOrSchema . fieldResolver
89
87
) :
90
88
graphqlImpl (
91
- schema ,
89
+ argsOrSchema ,
92
90
source ,
93
91
rootValue ,
94
92
contextValue ,
You can’t perform that action at this time.
0 commit comments