File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -576,7 +576,7 @@ export class Cacheable extends Hookified {
576576 * @param {WrapOptions } [options] The options for the wrap function
577577 * @returns {Function } The wrapped function
578578 */
579- public wrap < T > ( function_ : ( ...arguments_ : any [ ] ) => T , options ?: WrapFunctionOptions ) : ( ...arguments_ : any [ ] ) => T {
579+ public wrap < T , Arguments extends any [ ] > ( function_ : ( ...arguments_ : Arguments ) => T , options ?: WrapFunctionOptions ) : ( ...arguments_ : Arguments ) => T {
580580 const wrapOptions = {
581581 ttl : options ?. ttl ?? this . _ttl ,
582582 keyPrefix : options ?. keyPrefix ,
Original file line number Diff line number Diff line change @@ -598,7 +598,7 @@ export class CacheableMemory extends Hookified {
598598 * @param {Object } [options] - The options to wrap
599599 * @returns {Function } - The wrapped function
600600 */
601- public wrap < T > ( function_ : ( ...arguments_ : any [ ] ) => T , options ?: WrapFunctionOptions ) : ( ...arguments_ : any [ ] ) => T {
601+ public wrap < T , Arguments extends any [ ] > ( function_ : ( ...arguments_ : Arguments ) => T , options ?: WrapFunctionOptions ) : ( ...arguments_ : Arguments ) => T {
602602 const wrapOptions = {
603603 ttl : options ?. ttl ?? this . _ttl ,
604604 keyPrefix : options ?. keyPrefix ,
You can’t perform that action at this time.
0 commit comments