summaryrefslogtreecommitdiff
path: root/lib/bulk_imports/common/extractors/graphql_extractor.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bulk_imports/common/extractors/graphql_extractor.rb')
-rw-r--r--lib/bulk_imports/common/extractors/graphql_extractor.rb12
1 files changed, 4 insertions, 8 deletions
diff --git a/lib/bulk_imports/common/extractors/graphql_extractor.rb b/lib/bulk_imports/common/extractors/graphql_extractor.rb
index c0cef61d2b2..af274ee1299 100644
--- a/lib/bulk_imports/common/extractors/graphql_extractor.rb
+++ b/lib/bulk_imports/common/extractors/graphql_extractor.rb
@@ -11,14 +11,10 @@ module BulkImports
def extract(context)
client = graphql_client(context)
- Enumerator.new do |yielder|
- result = client.execute(
- client.parse(query.to_s),
- query.variables(context.entity)
- )
-
- yielder << result.original_hash.deep_dup
- end
+ client.execute(
+ client.parse(query.to_s),
+ query.variables(context.entity)
+ ).original_hash.deep_dup
end
private