mirror of
https://github.com/bitwarden/jslib
synced 2025-12-17 08:43:18 +00:00
added memory leak warning
This commit is contained in:
@@ -5,6 +5,8 @@
|
|||||||
* be returned, instead of calling the original function again
|
* be returned, instead of calling the original function again
|
||||||
*
|
*
|
||||||
* Results are not cached, once the promise has returned, the next call will result in a fresh call
|
* Results are not cached, once the promise has returned, the next call will result in a fresh call
|
||||||
|
*
|
||||||
|
* WARNING: The decorator's scope is singleton, so using it on transient objects can lead to memory leaks.
|
||||||
*/
|
*/
|
||||||
export function sequentialize(cacheKey: (args: any[]) => string) {
|
export function sequentialize(cacheKey: (args: any[]) => string) {
|
||||||
return (target: any, propertyKey: string | symbol, descriptor: PropertyDescriptor) => {
|
return (target: any, propertyKey: string | symbol, descriptor: PropertyDescriptor) => {
|
||||||
|
|||||||
Reference in New Issue
Block a user