Merge pull request #17227 from DefinitelyTyped/node-getopt-create

node-getopt: Fix type of `create`
This commit is contained in:
Nathan Shively-Sanders
2017-06-19 15:50:53 -07:00
committed by GitHub
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -122,7 +122,7 @@ declare class Getopt {
* equals new Getopt(options)
* @param options
*/
static create(options: string[]): Getopt;
static create(options: string[][]): Getopt;
}
export = Getopt;
+2 -2
View File
@@ -34,7 +34,7 @@ function help() {
function onedragon() {
// examples/onedragon.js
var opt = require('node-getopt').create([
var opt = Getopt.create([
['s' , '' , 'short option.'],
['' , 'long' , 'long option.'],
['S' , 'short-with-arg=ARG' , 'option with argument'],
@@ -52,7 +52,7 @@ function onedragon() {
function online(){
// node-getopt oneline example.
var opt = require('..').create([
var opt = Getopt.create([
['s' , '' , 'short option.'],
['' , 'long' , 'long option.'],
['S' , 'short-with-arg=ARG' , 'option with argument'],