From 49013b72776b3f83f191aaf306a2147d10e6d8a0 Mon Sep 17 00:00:00 2001 From: Daniel Herman Date: Mon, 7 Aug 2017 14:09:42 -0400 Subject: [PATCH] Correctly identify a few methods as polymorphic Since these methods return `this`, we should modify the return value to reflect that so that inherited classes have the return type appropriately identified as the inherited class --- types/raven/index.d.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/types/raven/index.d.ts b/types/raven/index.d.ts index 331aafa37a..610122ab66 100644 --- a/types/raven/index.d.ts +++ b/types/raven/index.d.ts @@ -33,9 +33,9 @@ export function parseDSN(dsn: string | false): parsedDSN; export class Client extends EventEmitter { constructor(options: ConstructorOptions); constructor(dsn: string, options?: ConstructorOptions); - config(dsn: string, options?: ConstructorOptions): Client; - install(options?: ConstructorOptions, cb?: () => void): Client; - setContext(ctx: any): Client; + config(dsn: string, options?: ConstructorOptions): this; + install(options?: ConstructorOptions, cb?: () => void): this; + setContext(ctx: any): this; requestHandler(): (req: IncomingMessage, res: ServerResponse, next: () => void) => void; errorHandler(): (e: Error, req: IncomingMessage, res: ServerResponse, next: () => void) => void; captureException(error: Error, cb?: CaptureCallback): string;