diff --git a/graph/schema.resolvers.go b/graph/schema.resolvers.go index cdb8206..458414d 100644 --- a/graph/schema.resolvers.go +++ b/graph/schema.resolvers.go @@ -138,7 +138,7 @@ func (r *queryResolver) User(ctx context.Context, id string) (*model.User, error // Todo is the resolver for the todo field. func (r *queryResolver) Todo(ctx context.Context, id string) (*model.Todo, error) { - return globals.DB.GetTodo(&model.Todo{ID: id}) + return globals.DB.GetTodo(&model.Todo{ID: id, User: &model.User{ID: auth.ForContext(ctx).UserId}}) } // Role is the resolver for the role field.