mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-12 13:00:19 +00:00
Fix to just make ClientRequestArgs an alias of RequestOptions
This commit is contained in:
Vendored
+5
-3
@@ -575,7 +575,7 @@ declare module "http" {
|
||||
[header: string]: number | string | string[] | undefined;
|
||||
}
|
||||
|
||||
export interface ClientRequestArgs {
|
||||
export interface RequestOptions {
|
||||
protocol?: string;
|
||||
host?: string;
|
||||
hostname?: string;
|
||||
@@ -591,6 +591,8 @@ declare module "http" {
|
||||
timeout?: number;
|
||||
}
|
||||
|
||||
export type ClientRequestArgs = RequestOptions
|
||||
|
||||
export interface Server extends net.Server {
|
||||
setTimeout(msecs: number, callback: Function): void;
|
||||
maxHeadersCount: number;
|
||||
@@ -731,7 +733,7 @@ declare module "http" {
|
||||
};
|
||||
export function createServer(requestListener?: (request: IncomingMessage, response: ServerResponse) =>void ): Server;
|
||||
export function createClient(port?: number, host?: string): any;
|
||||
export function request(options: ClientRequestArgs | string, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export function request(options: RequestOptions | string, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export function get(options: any, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export var globalAgent: Agent;
|
||||
}
|
||||
@@ -927,7 +929,7 @@ declare module "https" {
|
||||
SNICallback?: (servername: string) => any;
|
||||
}
|
||||
|
||||
export interface RequestOptions extends http.ClientRequestArgs {
|
||||
export interface RequestOptions extends http.RequestOptions {
|
||||
pfx?: any;
|
||||
key?: any;
|
||||
passphrase?: string;
|
||||
|
||||
Vendored
+5
-3
@@ -647,7 +647,7 @@ declare module "http" {
|
||||
[header: string]: number | string | string[] | undefined;
|
||||
}
|
||||
|
||||
export interface ClientRequestArgs {
|
||||
export interface RequestOptions {
|
||||
protocol?: string;
|
||||
host?: string;
|
||||
hostname?: string;
|
||||
@@ -663,6 +663,8 @@ declare module "http" {
|
||||
timeout?: number;
|
||||
}
|
||||
|
||||
export type ClientRequestArgs = RequestOptions
|
||||
|
||||
export interface Server extends net.Server {
|
||||
setTimeout(msecs: number, callback: Function): void;
|
||||
maxHeadersCount: number;
|
||||
@@ -809,7 +811,7 @@ declare module "http" {
|
||||
};
|
||||
export function createServer(requestListener?: (request: IncomingMessage, response: ServerResponse) => void): Server;
|
||||
export function createClient(port?: number, host?: string): any;
|
||||
export function request(options: ClientRequestArgs | string, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export function request(options: RequestOptions | string, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export function get(options: any, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export var globalAgent: Agent;
|
||||
}
|
||||
@@ -1334,7 +1336,7 @@ declare module "https" {
|
||||
SNICallback?: (servername: string, cb: (err: Error, ctx: tls.SecureContext) => any) => any;
|
||||
}
|
||||
|
||||
export interface RequestOptions extends http.ClientRequestArgs {
|
||||
export interface RequestOptions extends http.RequestOptions {
|
||||
pfx?: any;
|
||||
key?: any;
|
||||
passphrase?: string;
|
||||
|
||||
Vendored
+5
-3
@@ -664,7 +664,7 @@ declare module "http" {
|
||||
[header: string]: number | string | string[] | undefined;
|
||||
}
|
||||
|
||||
export interface ClientRequestArgs {
|
||||
export interface RequestOptions {
|
||||
protocol?: string;
|
||||
host?: string;
|
||||
hostname?: string;
|
||||
@@ -680,6 +680,8 @@ declare module "http" {
|
||||
timeout?: number;
|
||||
}
|
||||
|
||||
export type ClientRequestArgs = RequestOptions
|
||||
|
||||
export interface Server extends net.Server {
|
||||
setTimeout(msecs: number, callback: Function): void;
|
||||
maxHeadersCount: number;
|
||||
@@ -826,7 +828,7 @@ declare module "http" {
|
||||
};
|
||||
export function createServer(requestListener?: (request: IncomingMessage, response: ServerResponse) => void): Server;
|
||||
export function createClient(port?: number, host?: string): any;
|
||||
export function request(options: ClientRequestArgs | string, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export function request(options: RequestOptions | string, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export function get(options: any, callback?: (res: IncomingMessage) => void): ClientRequest;
|
||||
export var globalAgent: Agent;
|
||||
}
|
||||
@@ -1399,7 +1401,7 @@ declare module "https" {
|
||||
SNICallback?: (servername: string, cb: (err: Error, ctx: tls.SecureContext) => any) => any;
|
||||
}
|
||||
|
||||
export interface RequestOptions extends http.ClientRequestArgs {
|
||||
export interface RequestOptions extends http.RequestOptions {
|
||||
pfx?: any;
|
||||
key?: any;
|
||||
passphrase?: string;
|
||||
|
||||
Reference in New Issue
Block a user