Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

appolo-utils

Package Overview
Dependencies
Maintainers
1
Versions
60
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

appolo-utils - npm Package Compare versions

Comparing version 0.0.47 to 0.0.48

9

lib/promises.js

@@ -166,2 +166,11 @@ "use strict";

}
static promiseTimeout(promise, timeout) {
return new Promise((resolve, reject) => {
let interval = setTimeout(() => reject(new Error("promise timeout")), timeout);
promise
.then(resolve)
.catch(reject)
.finally(() => clearTimeout(interval));
});
}
}

@@ -168,0 +177,0 @@ exports.Promises = Promises;

@@ -227,2 +227,12 @@ type Resolvable<R> = R | PromiseLike<R>

}
public static promiseTimeout<T>(promise: Promise<T>, timeout: number): Promise<T> {
return new Promise<T>((resolve, reject) => {
let interval = setTimeout(() => reject(new Error("promise timeout")), timeout);
promise
.then(resolve)
.catch(reject)
.finally(() => clearTimeout(interval))
})
}
}

@@ -229,0 +239,0 @@

2

package.json

@@ -17,3 +17,3 @@ {

"main": "./index.js",
"version": "0.0.47",
"version": "0.0.48",
"license": "MIT",

@@ -20,0 +20,0 @@ "repository": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc