Skip to content

Commit 42b348a

Browse files
committed
delete post mutation
1 parent b9858f1 commit 42b348a

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

graphql/comment.graphql

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
extend type Mutation {
2+
createComment(content: String!): Comment! @guard
3+
}

graphql/post.graphql

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,16 @@ extend type Mutation {
1414
content: String!,
1515
category: Int!,
1616
): Post! @guard
17+
18+
updatePost(
19+
id: ID! @eq,
20+
title: String,
21+
content: String,
22+
category: Int,
23+
isPublished: Boolean,
24+
likes: Int,
25+
views: Int
26+
): Post @update @guard
27+
28+
deletePost(id: ID!): Post @guard @delete
1729
}

0 commit comments

Comments
 (0)