Skip to content

Commit

Permalink
fix: update graphql-compose version 7.12.0 & update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
nodkz committed Feb 15, 2020
1 parent 9035384 commit f6bc025
Show file tree
Hide file tree
Showing 8 changed files with 49 additions and 49 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@
"eslint-plugin-prettier": "3.1.2",
"express": "^4.17.1",
"express-graphql": "^0.9.0",
"flow-bin": "0.110.0",
"flow-bin": "0.118.0",
"graphql": "14.6.0",
"graphql-compose": "7.11.0",
"graphql-compose": "7.12.0",
"jest": "25.1.0",
"nodemon": "2.0.2",
"npm-run-all": "^4.1.5",
Expand Down
2 changes: 1 addition & 1 deletion src/elasticDSL/Query/Geo/GeoDistance.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export function getGeoDistanceITC<TContext>(
description: 'Eg. 12km',
},
distance_type: getDistanceCalculationModeFC(opts),
...fields,
...(fields: any),
validation_method: 'String',
},
}));
Expand Down
69 changes: 34 additions & 35 deletions src/elasticDSL/Query/Query.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,54 +56,53 @@ export function getQueryITC<TContext>(opts: CommonOpts<TContext>): InputTypeComp
return opts.getOrCreateITC(name, () => ({
name,
description,
// $FlowFixMe
fields: {
match_all: () => getMatchAllITC(opts),
match_all: getMatchAllITC(opts),

// Compound quries
bool: () => getBoolITC(opts),
constant_score: () => getConstantScoreITC(opts),
dis_max: () => getDisMaxITC(opts),
boosting: () => getBoostingITC(opts),
function_score: () => getFunctionScoreITC(opts),
bool: getBoolITC(opts),
constant_score: getConstantScoreITC(opts),
dis_max: getDisMaxITC(opts),
boosting: getBoostingITC(opts),
function_score: getFunctionScoreITC(opts),

// FullText queries
match: () => getMatchITC(opts),
match_phrase: () => getMatchPhraseITC(opts),
match_phrase_prefix: () => getMatchPhrasePrefixITC(opts),
multi_match: () => getMultiMatchITC(opts),
common: () => getCommonITC(opts),
query_string: () => getQueryStringITC(opts),
simple_query_string: () => getSimpleQueryStringITC(opts),
match: getMatchITC(opts),
match_phrase: getMatchPhraseITC(opts),
match_phrase_prefix: getMatchPhrasePrefixITC(opts),
multi_match: getMultiMatchITC(opts),
common: getCommonITC(opts),
query_string: getQueryStringITC(opts),
simple_query_string: getSimpleQueryStringITC(opts),

// Term queries
exists: () => getExistsITC(opts),
fuzzy: () => getFuzzyITC(opts),
ids: () => getIdsITC(opts),
prefix: () => getPrefixITC(opts),
range: () => getRangeITC(opts),
regexp: () => getRegexpITC(opts),
type: () => getTypeITC(opts),
term: () => getTermITC(opts),
terms: () => getTermsITC(opts),
wildcard: () => getWildcardITC(opts),
exists: getExistsITC(opts),
fuzzy: getFuzzyITC(opts),
ids: getIdsITC(opts),
prefix: getPrefixITC(opts),
range: getRangeITC(opts),
regexp: getRegexpITC(opts),
type: getTypeITC(opts),
term: getTermITC(opts),
terms: getTermsITC(opts),
wildcard: getWildcardITC(opts),

// Geo queries
geo_bounding_box: () => getGeoBoundingBoxITC(opts),
geo_distance: () => getGeoDistanceITC(opts),
geo_polygon: () => getGeoPolygonITC(opts),
geo_shape: () => getGeoShapeITC(opts),
geo_bounding_box: getGeoBoundingBoxITC(opts),
geo_distance: getGeoDistanceITC(opts),
geo_polygon: getGeoPolygonITC(opts),
geo_shape: getGeoShapeITC(opts),

// Specialized queries
more_like_this: () => getMoreLikeThisITC(opts),
percolate: () => getPercolateITC(opts),
script: () => getScriptITC(opts),
more_like_this: getMoreLikeThisITC(opts),
percolate: getPercolateITC(opts),
script: getScriptITC(opts),

// Joining queries
has_child: () => getHasChildITC(opts),
has_parent: () => getHasParentITC(opts),
nested: () => getNestedITC(opts),
parent_id: () => getParentIdITC(opts),
has_child: getHasChildITC(opts),
has_parent: getHasParentITC(opts),
nested: getNestedITC(opts),
parent_id: getParentIdITC(opts),
},
}));
}
Expand Down
1 change: 1 addition & 0 deletions src/resolvers/search.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ export default function createSearchResolver<TSource, TContext>(
.removeField(topLevelArgs);
Object.keys(argsConfigMap).forEach(argKey => {
if (topLevelArgs.indexOf(argKey) === -1) {
// $FlowFixMe
delete argsConfigMap[argKey];
}
});
Expand Down
2 changes: 1 addition & 1 deletion src/types/FindByIdOutput.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ export function getFindByIdOutputTC<TContext>(
_index: 'String',
_type: 'String',
_version: 'Int',
...sourceTC.getFields(),
...(sourceTC.getFields(): any),
},
}));
}
2 changes: 1 addition & 1 deletion src/types/UpdateByIdOutput.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export function getUpdateByIdOutputTC<TContext>(
_type: 'String',
_version: 'Int',
result: 'String',
...sourceTC.getFields(),
...(sourceTC.getFields(): any),
},
}));
}
2 changes: 1 addition & 1 deletion src/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export type CommonOpts<TContext = {}> = {

export function prepareCommonOpts<TContext>(
schemaComposer: SchemaComposer<TContext>,
opts: mixed = {}
opts: any = {}
): CommonOpts<TContext> {
return {
schemaComposer,
Expand Down
16 changes: 8 additions & 8 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3453,10 +3453,10 @@ flatted@^2.0.0:
resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.1.tgz#69e57caa8f0eacbc281d2e2cb458d46fdb449e08"
integrity sha512-a1hQMktqW9Nmqr5aktAux3JMNqaucxGcjtjWnZLHX7yyPCmlSV3M54nGYbqT8K+0GhF3NBgmJCc3ma+WOgX8Jg==

flow-bin@0.110.0:
version "0.110.0"
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.110.0.tgz#c6c140e239f662839d8f61b64b7b911f12d3306c"
integrity sha512-mmdEPEMoTuX+mguy/tjRlOlCtPfVdXZQeMgCAsEDVDgWMA5vwWhM2y653OcJiKX38t4gtZ2e/MNVo0qzyYeZDQ==
flow-bin@0.118.0:
version "0.118.0"
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.118.0.tgz#fb706364a58c682d67a2ca7df39396467dc397d1"
integrity sha512-jlbUu0XkbpXeXhan5xyTqVK1jmEKNxE8hpzznI3TThHTr76GiFwK0iRzhDo4KNy+S9h/KxHaqVhTP86vA6wHCg==

flush-write-stream@^1.0.0:
version "1.1.1"
Expand Down Expand Up @@ -3772,10 +3772,10 @@ graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6
resolved "https://registry.yarnpkg.com/graceful-readlink/-/graceful-readlink-1.0.1.tgz#4cafad76bc62f02fa039b2f94e9a3dd3a391a725"
integrity sha1-TK+tdrxi8C+gObL5Tpo906ORpyU=

graphql-compose@7.11.0:
version "7.11.0"
resolved "https://registry.yarnpkg.com/graphql-compose/-/graphql-compose-7.11.0.tgz#77e7435918f7f9a186ae9e939fa2c92c3bb85cdd"
integrity sha512-vmAaNA4BUM7PBe1PpujLRIsAlx1qjaoAsol1IvGQKBIi8TwdrLnFZEza0O7+AalqbmcP2eqZ5On/pALP/88ZiA==
graphql-compose@7.12.0:
version "7.12.0"
resolved "https://registry.yarnpkg.com/graphql-compose/-/graphql-compose-7.12.0.tgz#223e3c811c18e18e153be2c77c632afa3015477a"
integrity sha512-AbuQl2LfHYWtgVNJd8De2m8+KtJnkIXII8QkuSt2NMsniFc7DUuIp3MBaNPS9pRCA6l1OTGk2labuWRSyXZVlw==
dependencies:
graphql-type-json "^0.3.1"
object-path "^0.11.4"
Expand Down

0 comments on commit f6bc025

Please sign in to comment.