JMitnik / haas

haas
0 stars 0 forks source link

fix Nan -> 0 #479

Closed Cold-A-Muse closed 2 years ago

Cold-A-Muse commented 2 years ago

in this PR

FIXES HAAS-437 FIXES HAAS-436 all meanBy functions now have '|| 0' added to make sure the returned value is always a number (instead of NaN)

linear[bot] commented 2 years ago
HAAS-437 GraphQLError in GetWorkspaceLayoutDetails: Float cannot represent non numeric value: NaN

Sentry Issue: [HAAS-API-S1](https://sentry.io/organizations/haas/issues/3602108086/?referrer=Linear) ``` GraphQLError: Float cannot represent non numeric value: NaN File "/app/node_modules/graphql/type/scalars.js", line 106, col 11, in GraphQLScalarType.serializeFloat [as serialize] throw new _GraphQLError.GraphQLError("Float cannot represent non numeric value: ".concat((0, _inspect.default)(coercedValue))); File "/app/node_modules/graphql/execution/execute.js", line 653, col 37, in completeLeafValue var serializedResult = returnType.serialize(result); File "/app/node_modules/graphql/execution/execute.js", line 578, col 12, in completeValue return completeLeafValue(returnType, result); File "/app/node_modules/graphql/execution/execute.js", line 556, col 21, in completeValue var completed = completeValue(exeContext, returnType.ofType, fieldNodes, info, path, result); File "/app/node_modules/graphql/execution/execute.js", line 469, col 16, in null. return completeValue(exeContext, returnType, fieldNodes, info, path, resolved); ?, in async Promise.all ?, in async Promise.all ?, in async Promise.all ?, in async Promise.all File "async /app/node_modules/@envelop/core/cjs/orchestrator.js", line 380, col 27, in null. ```

HAAS-436 GraphQLError in GetDialogueLayoutDetails: Float cannot represent non numeric value: NaN

Sentry Issue: [HAAS-API-S3](https://sentry.io/organizations/haas/issues/3602108240/?referrer=Linear) ``` GraphQLError: Float cannot represent non numeric value: NaN File "/app/node_modules/graphql/type/scalars.js", line 106, col 11, in GraphQLScalarType.serializeFloat [as serialize] throw new _GraphQLError.GraphQLError("Float cannot represent non numeric value: ".concat((0, _inspect.default)(coercedValue))); File "/app/node_modules/graphql/execution/execute.js", line 653, col 37, in completeLeafValue var serializedResult = returnType.serialize(result); File "/app/node_modules/graphql/execution/execute.js", line 578, col 12, in completeValue return completeLeafValue(returnType, result); File "/app/node_modules/graphql/execution/execute.js", line 556, col 21, in completeValue var completed = completeValue(exeContext, returnType.ofType, fieldNodes, info, path, result); File "/app/node_modules/graphql/execution/execute.js", line 469, col 16, in null. return completeValue(exeContext, returnType, fieldNodes, info, path, resolved); ?, in async Promise.all ?, in async Promise.all ?, in async Promise.all ?, in async Promise.all File "async /app/node_modules/@envelop/core/cjs/orchestrator.js", line 380, col 27, in null. ```

aws-amplify-eu-central-1[bot] commented 2 years ago

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-479.d2j37lx5gsfgp1.amplifyapp.com

aws-amplify-eu-central-1[bot] commented 2 years ago

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-479.d36c61y3h9mqcx.amplifyapp.com