@@ -149,7 +149,7 @@ export declare class Response {
149
149
getHeader ( key : string ) : string ;
150
150
hasHeader ( key : string ) : boolean ;
151
151
removeHeader ( key : string ) : this;
152
- getLink ( s3Path : string , expires ?: number , callback ?: ( err , data ) => void ) ;
152
+ getLink ( s3Path : string , expires ?: number , callback ?: ErrorCallback ) : Promise < string > ;
153
153
send ( body : any ) : void ;
154
154
json ( body : any ) : void ;
155
155
jsonp ( body : any ) : void ;
@@ -159,16 +159,16 @@ export declare class Response {
159
159
redirect ( status : number , path : string ) : void ;
160
160
redirect ( path : string ) : void ;
161
161
cors ( options : CorsOptions ) : this;
162
- error ( message : string , detail ?: any ) ;
163
- error ( code : number , message : string , detail ?: any ) ;
162
+ error ( message : string , detail ?: any ) : void ;
163
+ error ( code : number , message : string , detail ?: any ) : void ;
164
164
cookie ( name : string , value : string , options ?: CookieOptions ) : this;
165
165
clearCookie ( name : string , options ?: CookieOptions ) : this;
166
166
etag ( enable ?: boolean ) : this;
167
167
cache ( age ?: boolean | number | string , private ?: boolean ) : this;
168
168
modified ( date : boolean | string | Date ) : this;
169
169
attachment ( fileName ?: string ) : this;
170
- download ( file : string | Buffer , fileName ?: string , options ?: FileOptions , callback ?: ErrorCallback ) ;
171
- sendFile ( file : string | Buffer , options ?: FileOptions , callback ?: ErrorCallback ) ;
170
+ download ( file : string | Buffer , fileName ?: string , options ?: FileOptions , callback ?: ErrorCallback ) : void ;
171
+ sendFile ( file : string | Buffer , options ?: FileOptions , callback ?: ErrorCallback ) : Promise < void > ;
172
172
}
173
173
174
174
export declare class API {
@@ -197,10 +197,10 @@ export declare class API {
197
197
198
198
199
199
200
- use ( path : string , ...middleware : Middleware [ ] ) ;
201
- use ( paths : string [ ] , ...middleware : Middleware [ ] ) ;
202
- use ( ...middleware : Middleware [ ] ) ;
203
- use ( ...errorHandlingMiddleware : ErrorHandlingMiddleware [ ] ) ;
200
+ use ( path : string , ...middleware : Middleware [ ] ) : void ;
201
+ use ( paths : string [ ] , ...middleware : Middleware [ ] ) : void ;
202
+ use ( ...middleware : Middleware [ ] ) : void ;
203
+ use ( ...errorHandlingMiddleware : ErrorHandlingMiddleware [ ] ) : void ;
204
204
205
205
finally ( callback : FinallyFunction ) : void ;
206
206
0 commit comments