graphql-tools-fork
Advanced tools
Comparing version 6.1.2 to 6.1.3
@@ -5,2 +5,11 @@ # Changelog | ||
### [6.1.3](https://github.com/yaacovCR/graphql-tools-fork/compare/v6.1.2...v6.1.3) (2019-07-03) | ||
### Bug Fixes | ||
* **stitching:** fix lists of enum and custom scalars, closes [#9](https://github.com/yaacovCR/graphql-tools-fork/issues/9) ([0d173b9](https://github.com/yaacovCR/graphql-tools-fork/commit/0d173b9)) | ||
### [6.1.2](https://github.com/yaacovCR/graphql-tools-fork/compare/v6.1.1...v6.1.2) (2019-07-01) | ||
@@ -7,0 +16,0 @@ |
@@ -33,14 +33,14 @@ Object.defineProperty(exports, "__esModule", { value: true }); | ||
} | ||
else if (graphql_1.isEnumType(nullableType)) { | ||
var value = nullableType.getValue(resultObject); | ||
if (value) { | ||
return value.value; | ||
} | ||
return parseOutputValue(nullableType, resultObject); | ||
} | ||
exports.handleResult = handleResult; | ||
function parseOutputValue(type, value) { | ||
if (graphql_1.isListType(type)) { | ||
return value.map(function (v) { return parseOutputValue(graphql_1.getNullableType(type.ofType), v); }); | ||
} | ||
else if (graphql_1.isScalarType(nullableType)) { | ||
return nullableType.parseValue(resultObject); | ||
else if (graphql_1.isEnumType(type) || graphql_1.isScalarType(type)) { | ||
return type.parseValue(value); | ||
} | ||
return resultObject; | ||
return value; | ||
} | ||
exports.handleResult = handleResult; | ||
//# sourceMappingURL=checkResultAndHandleErrors.js.map |
{ | ||
"name": "graphql-tools-fork", | ||
"version": "6.1.2", | ||
"version": "6.1.3", | ||
"description": "Forked graphql-tools, still more useful tools to create and manipulate GraphQL schemas.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
460969