Update formatError.d.ts

See e.g. the flow definition in https://github.com/graphql/graphql-js/blob/master/src/error/formatError.js, where they are defined as optional.
I'm no GraphQL expert; caveat emptor.
This commit is contained in:
Ed Staub
2017-06-27 13:36:34 -04:00
committed by GitHub
parent cab2a719f4
commit dc1ea691f9
+3 -3
View File
@@ -8,11 +8,11 @@ export function formatError(error: GraphQLError): GraphQLFormattedError;
export type GraphQLFormattedError = {
message: string,
locations: Array<GraphQLErrorLocation>,
path: Array<string | number>
locations?: Array<GraphQLErrorLocation>,
path?: Array<string | number>
};
export type GraphQLErrorLocation = {
line: number,
column: number
};
};