11var schemaToQuery = require ( './assets/gql-generator' ) . schemaToQuery ,
22 converter ,
33 util = require ( './util' ) ,
4- sdk = require ( 'postman-collection' ) ,
4+ { Collection } = require ( 'postman-collection/lib/collection/collection' ) ,
5+ { ItemGroup } = require ( 'postman-collection/lib/collection/item-group' ) ,
6+ { Variable } = require ( 'postman-collection/lib/collection/variable' ) ,
57 _ = require ( 'lodash' ) ,
68 graphql = require ( 'graphql' ) ;
79
@@ -227,7 +229,7 @@ converter = {
227229 convert : function ( input , options , callback ) {
228230 var gqlSchemaObj ,
229231 data ,
230- collection = new sdk . Collection ( ) ,
232+ collection = new Collection ( ) ,
231233 analysis ,
232234 queryCollection ;
233235
@@ -284,7 +286,7 @@ converter = {
284286 }
285287
286288 _ . forEach ( queryCollection , ( value , key ) => {
287- var folder = new sdk . ItemGroup ( ) ;
289+ var folder = new ItemGroup ( ) ;
288290 folder . name = key ;
289291 _ . forEach ( value , ( graphqlObj , name ) => {
290292 var request = { } ,
@@ -303,7 +305,7 @@ converter = {
303305 collection . items . add ( folder ) ;
304306 } ) ;
305307
306- collection . variables . add ( new sdk . Variable ( {
308+ collection . variables . add ( new Variable ( {
307309 id : 'url' ,
308310 value : '' ,
309311 description : 'URL for the request.'
0 commit comments