File tree Expand file tree Collapse file tree
libraries/rush-lib/src/utilities Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -16,15 +16,18 @@ import { Import, LegacyAdapters } from '@rushstack/node-core-library';
1616
1717const createHttpsProxyAgent : typeof import ( 'https-proxy-agent' ) = Import . lazy ( 'https-proxy-agent' , require ) ;
1818
19- /**
20- * For use with {@link WebClient}.
21- */
22- export interface IWebClientResponse {
19+ export interface IWebClientResponseBase {
2320 ok : boolean ;
2421 status : number ;
2522 statusText ?: string ;
2623 redirected : boolean ;
2724 headers : Record < string , string | string [ ] | undefined > ;
25+ }
26+
27+ /**
28+ * For use with {@link WebClient}.
29+ */
30+ export interface IWebClientResponse extends IWebClientResponseBase {
2831 getTextAsync : ( ) => Promise < string > ;
2932 getJsonAsync : < TJson > ( ) => Promise < TJson > ;
3033 getBufferAsync : ( ) => Promise < Buffer > ;
@@ -34,12 +37,7 @@ export interface IWebClientResponse {
3437 * A response from {@link WebClient.fetchStreamAsync} that provides the response body as a
3538 * readable stream, avoiding buffering the entire response in memory.
3639 */
37- export interface IWebClientStreamResponse {
38- ok : boolean ;
39- status : number ;
40- statusText ?: string ;
41- redirected : boolean ;
42- headers : Record < string , string | string [ ] | undefined > ;
40+ export interface IWebClientStreamResponse extends IWebClientResponseBase {
4341 stream : Readable ;
4442}
4543
You can’t perform that action at this time.
0 commit comments