wallet-core/node_modules/is-promise/index.js

6 lines
165 B
JavaScript
Raw Normal View History

2017-05-28 00:38:50 +02:00
module.exports = isPromise;
function isPromise(obj) {
return !!obj && (typeof obj === 'object' || typeof obj === 'function') && typeof obj.then === 'function';
}