You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{
"data": {
"createUser": null
},
"errors": [
{
"message": "Argument \"data\" is not a valid Document. obj.hasOwnProperty is not a function",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": [
"createUser"
],
"extensions": {
"code": "INTERNAL_SERVER_ERROR",
"exception": {
"stacktrace": [
"Error: Argument \"data\" is not a valid Document. obj.hasOwnProperty is not a function",
" at Validator.(anonymous function).values [as isDocument] (/sandbox/node_modules/@google-cloud/firestore/build/src/validate.js:92:27)",
" at CollectionReference.add (/sandbox/node_modules/@google-cloud/firestore/build/src/reference.js:1680:25)",
" at FirestoreDataSource.<anonymous> (/sandbox/node_modules/@gqlify/firestore/lib/index.js:129:70)",
" at step (/sandbox/node_modules/@gqlify/firestore/lib/index.js:32:23)",
" at Object.next (/sandbox/node_modules/@gqlify/firestore/lib/index.js:13:53)",
" at /sandbox/node_modules/@gqlify/firestore/lib/index.js:7:71",
" at new Promise (<anonymous>)",
" at __awaiter (/sandbox/node_modules/@gqlify/firestore/lib/index.js:3:12)",
" at FirestoreDataSource.create (/sandbox/node_modules/@gqlify/firestore/lib/index.js:125:16)",
" at CreatePlugin.<anonymous> (/sandbox/node_modules/@gqlify/server/lib/plugins/create.js:137:55)"
]
}
}
}
]
}
The obj.hasOwnProperty is not a function error may be due to graphql's usage of Object.create(null) when constructing args. See: graphql/express-graphql#177 (comment)
To Reproduce
Steps to reproduce the behavior:
2. Click on the Execute Query button in the GraphQL Playground window
3. See error
Expected behavior
A new users document to be created.
Describe the bug
My GraphQL Schema looks like this with
FirebaseDataSource
set up.Here's my
index.js
file:When I try to run a
createUser
migration with:Gives me this error:
The
obj.hasOwnProperty is not a function
error may be due to graphql's usage ofObject.create(null)
when constructingargs
. See: graphql/express-graphql#177 (comment)To Reproduce
Steps to reproduce the behavior:
2. Click on the
Execute Query
button in the GraphQL Playground window3. See error
Expected behavior
A new
users
document to be created.Versions:
The text was updated successfully, but these errors were encountered: