sdy

add deleteCategory resolver

...@@ -4,6 +4,11 @@ export default { ...@@ -4,6 +4,11 @@ export default {
4 Mutation: { 4 Mutation: {
5 deleteCategory: async (_, args) => { 5 deleteCategory: async (_, args) => {
6 const { name } = args; 6 const { name } = args;
7 + return prisma.category.delete({
8 + where: {
9 + name,
10 + },
11 + });
7 }, 12 },
8 }, 13 },
9 }; 14 };
......