summaryrefslogtreecommitdiff
path: root/bin/wiki/ImportarDesdeURL/node_modules/has-flag/index.js
diff options
context:
space:
mode:
Diffstat (limited to 'bin/wiki/ImportarDesdeURL/node_modules/has-flag/index.js')
-rw-r--r--bin/wiki/ImportarDesdeURL/node_modules/has-flag/index.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/bin/wiki/ImportarDesdeURL/node_modules/has-flag/index.js b/bin/wiki/ImportarDesdeURL/node_modules/has-flag/index.js
new file mode 100644
index 00000000..68820307
--- /dev/null
+++ b/bin/wiki/ImportarDesdeURL/node_modules/has-flag/index.js
@@ -0,0 +1,10 @@
+'use strict';
+module.exports = function (flag, argv) {
+ argv = argv || process.argv;
+
+ var terminatorPos = argv.indexOf('--');
+ var prefix = /^-{1,2}/.test(flag) ? '' : '--';
+ var pos = argv.indexOf(prefix + flag);
+
+ return pos !== -1 && (terminatorPos === -1 ? true : pos < terminatorPos);
+};