Skip to content

Instantly share code, notes, and snippets.

@armenr
Last active August 30, 2021 21:15
Show Gist options
  • Save armenr/4cdc0c58fadf7993cc0e91f466705278 to your computer and use it in GitHub Desktop.
Save armenr/4cdc0c58fadf7993cc0e91f466705278 to your computer and use it in GitHub Desktop.
datastore-warn
type Blog @model {
id: ID!
name: String!
posts: [Post] @connection(keyName: "byBlog", fields: ["id"])
}
type Post @model @key(name: "byBlog", fields: ["blogID"]) {
id: ID!
title: String!
blogID: ID!
blog: Blog @connection(fields: ["blogID"])
comments: [Comment] @connection(keyName: "byPost", fields: ["id"])
}
type Comment @model @key(name: "byPost", fields: ["postID", "content"]) {
id: ID!
postID: ID!
post: Post @connection(fields: ["postID"])
content: String!
}
type VodAsset
@model(subscriptions: { level: public })
@auth(
rules: [
{
allow: owner
ownerField: "owner"
operations: [create, update, delete, read]
}
{ allow: private, operations: [read] }
]
) {
id: ID!
title: String!
description: String!
#DO NOT EDIT
video: VideoObject @connection
}
#DO NOT EDIT
type VideoObject
@model
@auth(
rules: [
{
allow: owner
ownerField: "owner"
operations: [create, update, delete, read]
}
{ allow: private, operations: [read] }
]
) {
id: ID!
}
index.ad5cab3f.js:7 [WARN] 10:48.917 DataStore - subscriptionError Connection failed: {"errors":[{"message":"Validation error of type UnknownArgument: Unknown field argument owner @ 'onUpdateVideoObject'"}]}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment