[SuperAgent] Fix Response.error type (#42146)

* fix Response.error type

* remove trailing space
This commit is contained in:
Igor Morozov 2020-02-06 20:19:50 +03:00 committed by GitHub
parent ea7ace3ea1
commit d177ce08ba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -92,13 +92,20 @@ declare namespace request {
response?: Response;
}
interface HTTPError extends Error {
status: number;
text: string;
method: string;
path: string;
}
interface Response extends NodeJS.ReadableStream {
accepted: boolean;
badRequest: boolean;
body: any;
charset: string;
clientError: boolean;
error: ResponseError;
error: false | HTTPError;
files: any;
forbidden: boolean;
get(header: string): string;