@@ -9,7 +9,7 @@ const _extend = {
99 this . _query [ 'query' ] [ key ] [ type ] = value ;
1010 return this ;
1111 } else {
12- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
12+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
1313 }
1414 } ;
1515 } ,
@@ -22,7 +22,7 @@ const _extend = {
2222 this . _query [ 'query' ] [ key ] [ type ] = this . _query [ 'query' ] [ key ] [ type ] . concat ( value ) ;
2323 return this ;
2424 } else {
25- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
25+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
2626 }
2727 } ;
2828 } ,
@@ -33,7 +33,7 @@ const _extend = {
3333 this . _query [ 'query' ] [ key ] [ '$exists' ] = bool ;
3434 return this ;
3535 } else {
36- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
36+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
3737 }
3838 } ;
3939 } ,
@@ -61,7 +61,7 @@ const _extend = {
6161 this . _query [ type ] = key ;
6262 return this ;
6363 } else {
64- this . fetchOptions . logHandler ( 'error' , "Argument should be a string." ) ;
64+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Argument should be a string." ) ;
6565 }
6666 } ;
6767 } ,
@@ -71,7 +71,7 @@ const _extend = {
7171 this . _query [ type ] = value ;
7272 return this ;
7373 } else {
74- this . fetchOptions . logHandler ( 'error' , "Argument should be a number." ) ;
74+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Argument should be a number." ) ;
7575 }
7676 }
7777 }
@@ -395,7 +395,7 @@ export default class Query extends Entry {
395395
396396 return this ;
397397 } else {
398- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
398+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
399399 }
400400 }
401401
@@ -420,7 +420,7 @@ export default class Query extends Entry {
420420 this . _query [ 'query' ] [ key ] = value ;
421421 return this ;
422422 } else {
423- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
423+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
424424 }
425425 }
426426
@@ -476,7 +476,7 @@ export default class Query extends Entry {
476476 this . _query [ 'query' ] = Utils . mergeDeep ( this . _query [ 'query' ] , query ) ;
477477 return this ;
478478 } else {
479- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters" ) ;
479+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters" ) ;
480480 }
481481 }
482482
@@ -587,7 +587,7 @@ export default class Query extends Entry {
587587 this . _query [ 'tags' ] = values ;
588588 return this ;
589589 } else {
590- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters" ) ;
590+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters" ) ;
591591 }
592592 }
593593
@@ -651,7 +651,7 @@ export default class Query extends Entry {
651651 this . _query [ key ] = value ;
652652 return this ;
653653 } else {
654- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
654+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
655655 }
656656 }
657657
@@ -691,7 +691,7 @@ export default class Query extends Entry {
691691 if ( options ) this . _query [ 'query' ] [ key ] [ '$options' ] = options ;
692692 return this ;
693693 } else {
694- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
694+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
695695 }
696696 }
697697
@@ -717,7 +717,7 @@ export default class Query extends Entry {
717717 this . _query [ 'typeahead' ] = value ;
718718 return this ;
719719 } else {
720- this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
720+ if ( this . fetchOptions . debug ) this . fetchOptions . logHandler ( 'error' , "Kindly provide valid parameters." ) ;
721721 }
722722 }
723723
0 commit comments