File tree Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 11{
22 "name" : " helyosjs-sdk" ,
3- "version" : " 2.0.2 " ,
3+ "version" : " 2.0.3 " ,
44 "description" : " Comunication with helyos postgress database using graphql interface" ,
55 "main" : " dist/index.js" ,
66 "types" : " dist/index.d.ts" ,
Original file line number Diff line number Diff line change @@ -124,7 +124,6 @@ import { H_MissionQueue } from '../helyos.models';
124124 const postMessage = { id : wprocess . id , missionQueuePatch : patch } ;
125125 return this . _client . mutate ( { mutation : UPDATE , variables : { postMessage } } )
126126 . then ( response => {
127- console . log ( 'create request' , response ) ;
128127 return response ;
129128 } )
130129 . catch ( e => {
@@ -135,8 +134,6 @@ import { H_MissionQueue } from '../helyos.models';
135134
136135
137136 get ( missionQueueId : string ) : Promise < any > {
138- console . log ( "id" , missionQueueId )
139-
140137 const QUERY_FUNTCION = 'missionQueueById' ;
141138 const QUERY_STR = gql `
142139 query ${ QUERY_FUNTCION } ($missionQueueId: BigInt! ){
Original file line number Diff line number Diff line change @@ -5,6 +5,10 @@ const isObject = (value) => (typeof value === 'object');
55const isString = ( value ) => ( typeof value === 'string' || value instanceof String )
66
77export const gqlJsonResponseHandler = ( res : any , queryName : string ) => {
8+ if ( ! res . data [ queryName ] ) {
9+ return null ;
10+ }
11+
812 if ( res . data [ queryName ] . edges ) {
913 return res . data [ queryName ] . edges . map ( ( gqlElement : any ) => gqlElement . node ) ;
1014 } else {
You can’t perform that action at this time.
0 commit comments