mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-05 17:00:08 +00:00
Merge pull request #24447 from pobed2/patch-1
[graphql] Add `extensions` to GraphQLError
This commit is contained in:
6
types/graphql/error/GraphQLError.d.ts
vendored
6
types/graphql/error/GraphQLError.d.ts
vendored
@@ -56,6 +56,11 @@ export class GraphQLError extends Error {
|
||||
* The original error thrown from a field resolver during execution.
|
||||
*/
|
||||
originalError?: Error;
|
||||
|
||||
/**
|
||||
* Extension fields to add to the formatted error.
|
||||
*/
|
||||
extensions?: { [key: string]: any } | undefined;
|
||||
|
||||
constructor(
|
||||
message: string,
|
||||
@@ -64,5 +69,6 @@ export class GraphQLError extends Error {
|
||||
positions?: number[],
|
||||
path?: Array<string | number>,
|
||||
originalError?: Error,
|
||||
extensions?: { [key: string]: any },
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user