diff --git a/node_modules/once/package.json b/node_modules/once/package.json index 3a714c45e44..f5fd8173cb1 100644 --- a/node_modules/once/package.json +++ b/node_modules/once/package.json @@ -1,44 +1,97 @@ { - "name": "once", - "version": "1.3.2", - "description": "Run a function exactly one time", - "main": "once.js", - "directories": { - "test": "test" + "_args": [ + [ + "once@~1.3.3", + "/Users/ogd/Documents/projects/npm/npm" + ] + ], + "_from": "once@>=1.3.3 <1.4.0", + "_id": "once@1.3.3", + "_inCache": true, + "_installable": true, + "_location": "/once", + "_nodeVersion": "4.0.0", + "_npmUser": { + "email": "i@izs.me", + "name": "isaacs" + }, + "_npmVersion": "3.3.2", + "_phantomChildren": {}, + "_requested": { + "name": "once", + "raw": "once@~1.3.3", + "rawSpec": "~1.3.3", + "scope": null, + "spec": ">=1.3.3 <1.4.0", + "type": "range" + }, + "_requiredBy": [ + "/", + "/glob", + "/inflight", + "/node-gyp/glob", + "/npm-registry-client", + "/read-package-tree", + "/readdir-scoped-modules", + "/standard/standard-engine/eslint/file-entry-cache/flat-cache/del/globby/glob", + "/standard/standard-engine/eslint/inquirer/run-async", + "/tap/nyc/istanbul" + ], + "_resolved": "https://registry.npmjs.org/once/-/once-1.3.3.tgz", + "_shasum": "b2e261557ce4c314ec8304f3fa82663e4297ca20", + "_shrinkwrap": null, + "_spec": "once@~1.3.3", + "_where": "/Users/ogd/Documents/projects/npm/npm", + "author": { + "email": "i@izs.me", + "name": "Isaac Z. Schlueter", + "url": "http://blog.izs.me/" + }, + "bugs": { + "url": "https://github.com/isaacs/once/issues" }, "dependencies": { "wrappy": "1" }, + "description": "Run a function exactly one time", "devDependencies": { - "tap": "~0.3.0" + "tap": "^1.2.0" }, - "scripts": { - "test": "tap test/*.js" + "directories": { + "test": "test" }, - "repository": { - "type": "git", - "url": "git://github.com/isaacs/once.git" + "dist": { + "shasum": "b2e261557ce4c314ec8304f3fa82663e4297ca20", + "tarball": "http://registry.npmjs.org/once/-/once-1.3.3.tgz" }, + "files": [ + "once.js" + ], + "gitHead": "2ad558657e17fafd24803217ba854762842e4178", + "homepage": "https://github.com/isaacs/once#readme", "keywords": [ - "once", "function", + "once", "one", "single" ], - "author": { - "name": "Isaac Z. Schlueter", - "email": "i@izs.me", - "url": "http://blog.izs.me/" - }, "license": "ISC", - "readme": "# once\n\nOnly call a function once.\n\n## usage\n\n```javascript\nvar once = require('once')\n\nfunction load (file, cb) {\n cb = once(cb)\n loader.load('file')\n loader.once('load', cb)\n loader.once('error', cb)\n}\n```\n\nOr add to the Function.prototype in a responsible way:\n\n```javascript\n// only has to be done once\nrequire('once').proto()\n\nfunction load (file, cb) {\n cb = cb.once()\n loader.load('file')\n loader.once('load', cb)\n loader.once('error', cb)\n}\n```\n\nIronically, the prototype feature makes this module twice as\ncomplicated as necessary.\n\nTo check whether you function has been called, use `fn.called`. Once the\nfunction is called for the first time the return value of the original\nfunction is saved in `fn.value` and subsequent calls will continue to\nreturn this value.\n\n```javascript\nvar once = require('once')\n\nfunction load (cb) {\n cb = once(cb)\n var stream = createStream()\n stream.once('data', cb)\n stream.once('end', function () {\n if (!cb.called) cb(new Error('not found'))\n })\n}\n```\n", - "readmeFilename": "README.md", - "bugs": { - "url": "https://github.com/isaacs/once/issues" + "main": "once.js", + "maintainers": [ + { + "name": "isaacs", + "email": "i@izs.me" + } + ], + "name": "once", + "optionalDependencies": {}, + "readme": "ERROR: No README data found!", + "repository": { + "type": "git", + "url": "git://github.com/isaacs/once.git" }, - "homepage": "https://github.com/isaacs/once#readme", - "_id": "once@1.3.2", - "_shasum": "d8feeca93b039ec1dcdee7741c92bdac5e28081b", - "_resolved": "https://registry.npmjs.org/once/-/once-1.3.2.tgz", - "_from": "once@>=1.3.2 <1.4.0" + "scripts": { + "test": "tap test/*.js" + }, + "version": "1.3.3" } diff --git a/node_modules/once/test/once.js b/node_modules/once/test/once.js deleted file mode 100644 index c618360dfae..00000000000 --- a/node_modules/once/test/once.js +++ /dev/null @@ -1,23 +0,0 @@ -var test = require('tap').test -var once = require('../once.js') - -test('once', function (t) { - var f = 0 - function fn (g) { - t.equal(f, 0) - f ++ - return f + g + this - } - fn.ownProperty = {} - var foo = once(fn) - t.equal(fn.ownProperty, foo.ownProperty) - t.notOk(foo.called) - for (var i = 0; i < 1E3; i++) { - t.same(f, i === 0 ? 0 : 1) - var g = foo.call(1, 1) - t.ok(foo.called) - t.same(g, 3) - t.same(f, 1) - } - t.end() -}) diff --git a/package.json b/package.json index 33e61b78f32..6c555c57cfe 100644 --- a/package.json +++ b/package.json @@ -71,7 +71,7 @@ "npm-registry-client": "~7.0.9", "npm-user-validate": "~0.1.2", "npmlog": "~2.0.0", - "once": "~1.3.2", + "once": "~1.3.3", "opener": "~1.4.1", "osenv": "~0.1.3", "path-is-inside": "~1.0.1",