Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/yargs/lib/is-promise.js')
-rw-r--r--node_modules/yargs/lib/is-promise.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/node_modules/yargs/lib/is-promise.js b/node_modules/yargs/lib/is-promise.js
new file mode 100644
index 000000000..271d93b2d
--- /dev/null
+++ b/node_modules/yargs/lib/is-promise.js
@@ -0,0 +1,3 @@
+module.exports = function isPromise (maybePromise) {
+ return !!maybePromise && !!maybePromise.then && (typeof maybePromise.then === 'function')
+}