Some fix with Apollo
This commit is contained in:
@@ -1,12 +1,11 @@
|
||||
import mongoose from 'mongoose';
|
||||
const { Schema } = mongoose;
|
||||
import timestamps from 'mongoose-timestamp';
|
||||
import { composeWithMongoose } from 'graphql-compose-mongoose';
|
||||
|
||||
export const TaskSchema = new Schema(
|
||||
export const TaskSchema = new mongoose.Schema(
|
||||
{
|
||||
user: {
|
||||
type: Schema.Types.ObjectId,
|
||||
type: mongoose.Schema.Types.ObjectId,
|
||||
ref: 'User',
|
||||
required: true,
|
||||
},
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
import mongoose from 'mongoose';
|
||||
const { Schema } = mongoose
|
||||
import timestamps from 'mongoose-timestamp';
|
||||
import { composeWithMongoose } from 'graphql-compose-mongoose';
|
||||
|
||||
export const UserSchema = new Schema(
|
||||
export const UserSchema = new mongoose.Schema(
|
||||
{
|
||||
name: {
|
||||
type: String,
|
||||
|
||||
Reference in New Issue
Block a user