Skip to content

Commit b1b734b

Browse files
committed
Only call validate from findOperationDefinition
1 parent 9184e91 commit b1b734b

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

src/GraphQLService.cpp

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1835,20 +1835,6 @@ std::future<response::Value> Request::resolve(std::launch launch,
18351835
const std::shared_ptr<RequestState>& state, peg::ast& query, const std::string& operationName,
18361836
response::Value&& variables) const
18371837
{
1838-
auto errors = validate(query);
1839-
1840-
if (!errors.empty())
1841-
{
1842-
std::promise<response::Value> promise;
1843-
response::Value document(response::Type::Map);
1844-
1845-
document.emplace_back(std::string { strData }, response::Value());
1846-
document.emplace_back(std::string { strErrors }, buildErrorValues(errors));
1847-
promise.set_value(std::move(document));
1848-
1849-
return promise.get_future();
1850-
}
1851-
18521838
try
18531839
{
18541840
FragmentDefinitionVisitor fragmentVisitor(variables);

0 commit comments

Comments
 (0)