Skip to content
This repository has been archived by the owner on Dec 8, 2021. It is now read-only.

Commit

Permalink
fix(cgg): default createUser name arg to null (#397)
Browse files Browse the repository at this point in the history
Since version 0.5.0 of graphglgen args can be not just nullable but voidable. This more precise type introduced a type error with the existing template where a model expecting only nullable now received a voidable.
  • Loading branch information
Nuno Vieira authored and Jason Kuhrt committed Jan 20, 2019
1 parent cd14864 commit db10ee1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
// Code generated by github.com/prisma/graphqlgen, DO NOT EDIT.

import { GraphQLResolveInfo } from 'graphql'
import { Post, User } from '../types'
import { Context } from '../types'
import { Post, User, Context } from '../types'

export namespace QueryResolvers {
export const defaultResolvers = {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ type Query {
}

type Mutation {
createUser(name: String): User!
createUser(name: String = null): User!
createDraft(title: String!, content: String!, authorId: ID!): Post!
deletePost(id: ID!): Post
publish(id: ID!): Post
Expand Down

0 comments on commit db10ee1

Please sign in to comment.