Ocelot-Social/backend/src/graphql-schema.js
Wolfgang Huß 6a01146647 Refactored mutation "follow"
Done by @Tirokk and @mattwr18 .
2019-04-10 14:11:13 +02:00

32 lines
797 B
JavaScript

import fs from 'fs'
import path from 'path'
import userManagement from './resolvers/user_management.js'
import statistics from './resolvers/statistics.js'
import reports from './resolvers/reports.js'
import posts from './resolvers/posts.js'
import moderation from './resolvers/moderation.js'
import follow from './resolvers/follow.js'
import rewards from './resolvers/rewards.js'
export const typeDefs = fs
.readFileSync(
process.env.GRAPHQL_SCHEMA || path.join(__dirname, 'schema.graphql')
)
.toString('utf-8')
export const resolvers = {
Query: {
...statistics.Query,
...userManagement.Query
},
Mutation: {
...userManagement.Mutation,
...reports.Mutation,
...posts.Mutation,
...moderation.Mutation,
...follow.Mutation,
...rewards.Mutation
}
}