Browse Source

Update

master
Yutsuo 6 years ago
parent
commit
2101cfb87e
  1. 11
      .vscode/launch.json
  2. 37
      .vscode/tasks.json
  3. 0
      dist/bin/www.js
  4. 12
      node_modules/accepts/package.json
  5. 2
      node_modules/array-flatten/package.json
  6. 12
      node_modules/basic-auth/package.json
  7. 21
      node_modules/body-parser/HISTORY.md
  8. 2
      node_modules/body-parser/README.md
  9. 2
      node_modules/body-parser/lib/types/urlencoded.js
  10. 52
      node_modules/body-parser/package.json
  11. 5
      node_modules/bytes/History.md
  12. 13
      node_modules/bytes/Readme.md
  13. 9
      node_modules/bytes/index.js
  14. 28
      node_modules/bytes/package.json
  15. 5
      node_modules/content-disposition/HISTORY.md
  16. 2
      node_modules/content-disposition/LICENSE
  17. 23
      node_modules/content-disposition/README.md
  18. 47
      node_modules/content-disposition/index.js
  19. 51
      node_modules/content-disposition/package.json
  20. 2
      node_modules/content-type/package.json
  21. 7
      node_modules/cookie-parser/HISTORY.md
  22. 39
      node_modules/cookie-parser/README.md
  23. 43
      node_modules/cookie-parser/package.json
  24. 2
      node_modules/cookie-signature/package.json
  25. 5
      node_modules/cookie/HISTORY.md
  26. 109
      node_modules/cookie/README.md
  27. 3
      node_modules/cookie/index.js
  28. 35
      node_modules/cookie/package.json
  29. 1
      node_modules/debug/.coveralls.yml
  30. 11
      node_modules/debug/.eslintrc
  31. 9
      node_modules/debug/.npmignore
  32. 14
      node_modules/debug/.travis.yml
  33. 35
      node_modules/debug/CHANGELOG.md
  34. 50
      node_modules/debug/Makefile
  35. 269
      node_modules/debug/README.md
  36. 19
      node_modules/debug/component.json
  37. 70
      node_modules/debug/karma.conf.js
  38. 1
      node_modules/debug/node.js
  39. 73
      node_modules/debug/package.json
  40. 291
      node_modules/debug/src/browser.js
  41. 202
      node_modules/debug/src/debug.js
  42. 8
      node_modules/debug/src/index.js
  43. 15
      node_modules/debug/src/inspector-log.js
  44. 339
      node_modules/debug/src/node.js
  45. 3
      node_modules/depd/package.json
  46. 2
      node_modules/destroy/package.json
  47. 2
      node_modules/ee-first/package.json
  48. 2
      node_modules/encodeurl/package.json
  49. 2
      node_modules/escape-html/package.json
  50. 2
      node_modules/etag/package.json
  51. 74
      node_modules/express/History.md
  52. 14
      node_modules/express/Readme.md
  53. 2
      node_modules/express/lib/express.js
  54. 4
      node_modules/express/lib/request.js
  55. 7
      node_modules/express/lib/response.js
  56. 62
      node_modules/express/package.json
  57. 7
      node_modules/finalhandler/HISTORY.md
  58. 2
      node_modules/finalhandler/README.md
  59. 2
      node_modules/finalhandler/index.js
  60. 50
      node_modules/finalhandler/package.json
  61. 2
      node_modules/forwarded/package.json
  62. 2
      node_modules/fresh/package.json
  63. 19
      node_modules/http-errors/HISTORY.md
  64. 54
      node_modules/http-errors/README.md
  65. 28
      node_modules/http-errors/index.js
  66. 47
      node_modules/http-errors/package.json
  67. 23
      node_modules/iconv-lite/.travis.yml
  68. 4
      node_modules/iconv-lite/Changelog.md
  69. 4
      node_modules/iconv-lite/encodings/sbcs-codec.js
  70. 5
      node_modules/iconv-lite/encodings/sbcs-data.js
  71. 24
      node_modules/iconv-lite/package.json
  72. 7
      node_modules/inherits/package.json
  73. 2
      node_modules/ipaddr.js/README.md
  74. 15
      node_modules/ipaddr.js/lib/ipaddr.js.d.ts
  75. 25
      node_modules/ipaddr.js/package.json
  76. 2
      node_modules/media-typer/package.json
  77. 2
      node_modules/merge-descriptors/package.json
  78. 2
      node_modules/methods/package.json
  79. 7
      node_modules/mime-db/HISTORY.md
  80. 6
      node_modules/mime-db/README.md
  81. 134
      node_modules/mime-db/db.json
  82. 37
      node_modules/mime-db/package.json
  83. 8
      node_modules/mime-types/HISTORY.md
  84. 20
      node_modules/mime-types/README.md
  85. 27
      node_modules/mime-types/package.json
  86. 11
      node_modules/mime/build/build.js
  87. 60
      node_modules/mime/build/test.js
  88. 34
      node_modules/mime/package.json
  89. 2
      node_modules/mime/types.json
  90. 13
      node_modules/morgan/HISTORY.md
  91. 39
      node_modules/morgan/README.md
  92. 26
      node_modules/morgan/index.js
  93. 52
      node_modules/morgan/package.json
  94. 48
      node_modules/ms/index.js
  95. 36
      node_modules/ms/package.json
  96. 27
      node_modules/ms/readme.md
  97. 2
      node_modules/negotiator/package.json
  98. 2
      node_modules/on-finished/package.json
  99. 12
      node_modules/on-headers/package.json
  100. 12
      node_modules/parseurl/package.json
  101. Some files were not shown because too many files have changed in this diff Show More

11
.vscode/launch.json vendored

@ -1,11 +0,0 @@
{
"configurations": [
{
"name": "Docker Node.js Launch and Attach",
"type": "docker",
"request": "launch",
"preLaunchTask": "docker-run: debug",
"platform": "node"
}
]
}

37
.vscode/tasks.json vendored

@ -1,37 +0,0 @@
{
"tasks": [
{
"type": "docker-build",
"label": "docker-build",
"platform": "node",
"dockerBuild": {
"dockerfile": "${workspaceFolder}/Dockerfile",
"context": "${workspaceFolder}"
}
},
{
"type": "docker-run",
"label": "docker-run: release",
"dependsOn": [
"docker-build"
],
"platform": "node"
},
{
"type": "docker-run",
"label": "docker-run: debug",
"dependsOn": [
"docker-build"
],
"dockerRun": {
"env": {
"DEBUG": "*",
"NODE_ENV": "development"
}
},
"node": {
"enableDebugging": true
}
}
]
}

0
dist/bin/www.js vendored

12
node_modules/accepts/package.json generated vendored

@ -1,5 +1,5 @@
{ {
"_from": "accepts@~1.3.5", "_from": "accepts@~1.3.7",
"_id": "accepts@1.3.7", "_id": "accepts@1.3.7",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", "_integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==",
@ -8,20 +8,20 @@
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "accepts@~1.3.5", "raw": "accepts@~1.3.7",
"name": "accepts", "name": "accepts",
"escapedName": "accepts", "escapedName": "accepts",
"rawSpec": "~1.3.5", "rawSpec": "~1.3.7",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~1.3.5" "fetchSpec": "~1.3.7"
}, },
"_requiredBy": [ "_requiredBy": [
"/express" "/express"
], ],
"_resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", "_resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz",
"_shasum": "531bc726517a3b2b41f850021c6cc15eaab507cd", "_shasum": "531bc726517a3b2b41f850021c6cc15eaab507cd",
"_spec": "accepts@~1.3.5", "_spec": "accepts@~1.3.7",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/accepts/issues" "url": "https://github.com/jshttp/accepts/issues"
}, },

2
node_modules/array-flatten/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", "_resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz",
"_shasum": "9a5f699051b1e7073328f2a008968b64ea2955d2", "_shasum": "9a5f699051b1e7073328f2a008968b64ea2955d2",
"_spec": "array-flatten@1.1.1", "_spec": "array-flatten@1.1.1",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"author": { "author": {
"name": "Blake Embrey", "name": "Blake Embrey",
"email": "hello@blakeembrey.com", "email": "hello@blakeembrey.com",

12
node_modules/basic-auth/package.json generated vendored

@ -1,5 +1,5 @@
{ {
"_from": "basic-auth@~2.0.0", "_from": "basic-auth@~2.0.1",
"_id": "basic-auth@2.0.1", "_id": "basic-auth@2.0.1",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-NF+epuEdnUYVlGuhaxbbq+dvJttwLnGY+YixlXlME5KpQ5W3CnXA5cVTneY3SPbPDRkcjMbifrwmFYcClgOZeg==", "_integrity": "sha512-NF+epuEdnUYVlGuhaxbbq+dvJttwLnGY+YixlXlME5KpQ5W3CnXA5cVTneY3SPbPDRkcjMbifrwmFYcClgOZeg==",
@ -8,20 +8,20 @@
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "basic-auth@~2.0.0", "raw": "basic-auth@~2.0.1",
"name": "basic-auth", "name": "basic-auth",
"escapedName": "basic-auth", "escapedName": "basic-auth",
"rawSpec": "~2.0.0", "rawSpec": "~2.0.1",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~2.0.0" "fetchSpec": "~2.0.1"
}, },
"_requiredBy": [ "_requiredBy": [
"/morgan" "/morgan"
], ],
"_resolved": "https://registry.npmjs.org/basic-auth/-/basic-auth-2.0.1.tgz", "_resolved": "https://registry.npmjs.org/basic-auth/-/basic-auth-2.0.1.tgz",
"_shasum": "b998279bf47ce38344b4f3cf916d4679bbf51e3a", "_shasum": "b998279bf47ce38344b4f3cf916d4679bbf51e3a",
"_spec": "basic-auth@~2.0.0", "_spec": "basic-auth@~2.0.1",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/morgan", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/morgan",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/basic-auth/issues" "url": "https://github.com/jshttp/basic-auth/issues"
}, },

21
node_modules/body-parser/HISTORY.md generated vendored

@ -1,3 +1,24 @@
1.19.0 / 2019-04-25
===================
* deps: bytes@3.1.0
- Add petabyte (`pb`) support
* deps: http-errors@1.7.2
- Set constructor name when possible
- deps: setprototypeof@1.1.1
- deps: statuses@'>= 1.5.0 < 2'
* deps: iconv-lite@0.4.24
- Added encoding MIK
* deps: qs@6.7.0
- Fix parsing array brackets after index
* deps: raw-body@2.4.0
- deps: bytes@3.1.0
- deps: http-errors@1.7.2
- deps: iconv-lite@0.4.24
* deps: type-is@~1.6.17
- deps: mime-types@~2.1.24
- perf: prevent internal `throw` on invalid type
1.18.3 / 2018-05-14 1.18.3 / 2018-05-14
=================== ===================

2
node_modules/body-parser/README.md generated vendored

@ -399,13 +399,11 @@ var urlencodedParser = bodyParser.urlencoded({ extended: false })
// POST /login gets urlencoded bodies // POST /login gets urlencoded bodies
app.post('/login', urlencodedParser, function (req, res) { app.post('/login', urlencodedParser, function (req, res) {
if (!req.body) return res.sendStatus(400)
res.send('welcome, ' + req.body.username) res.send('welcome, ' + req.body.username)
}) })
// POST /api/users gets JSON bodies // POST /api/users gets JSON bodies
app.post('/api/users', jsonParser, function (req, res) { app.post('/api/users', jsonParser, function (req, res) {
if (!req.body) return res.sendStatus(400)
// create user in req.body // create user in req.body
}) })
``` ```

2
node_modules/body-parser/lib/types/urlencoded.js generated vendored

@ -266,7 +266,7 @@ function simpleparser (options) {
} }
debug('parse urlencoding') debug('parse urlencoding')
return parse(body, undefined, undefined, {maxKeys: parameterLimit}) return parse(body, undefined, undefined, { maxKeys: parameterLimit })
} }
} }

52
node_modules/body-parser/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "body-parser@1.18.3", "_from": "body-parser@1.19.0",
"_id": "body-parser@1.18.3", "_id": "body-parser@1.19.0",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha1-WykhmP/dVTs6DyDe0FkrlWlVyLQ=", "_integrity": "sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==",
"_location": "/body-parser", "_location": "/body-parser",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "body-parser@1.18.3", "raw": "body-parser@1.19.0",
"name": "body-parser", "name": "body-parser",
"escapedName": "body-parser", "escapedName": "body-parser",
"rawSpec": "1.18.3", "rawSpec": "1.19.0",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "1.18.3" "fetchSpec": "1.19.0"
}, },
"_requiredBy": [ "_requiredBy": [
"/express" "/express"
], ],
"_resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.18.3.tgz", "_resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz",
"_shasum": "5b292198ffdd553b3a0f20ded0592b956955c8b4", "_shasum": "96b2709e57c9c4e09a6fd66a8fd979844f69f08a",
"_spec": "body-parser@1.18.3", "_spec": "body-parser@1.19.0",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"bugs": { "bugs": {
"url": "https://github.com/expressjs/body-parser/issues" "url": "https://github.com/expressjs/body-parser/issues"
}, },
@ -38,32 +38,32 @@
} }
], ],
"dependencies": { "dependencies": {
"bytes": "3.0.0", "bytes": "3.1.0",
"content-type": "~1.0.4", "content-type": "~1.0.4",
"debug": "2.6.9", "debug": "2.6.9",
"depd": "~1.1.2", "depd": "~1.1.2",
"http-errors": "~1.6.3", "http-errors": "1.7.2",
"iconv-lite": "0.4.23", "iconv-lite": "0.4.24",
"on-finished": "~2.3.0", "on-finished": "~2.3.0",
"qs": "6.5.2", "qs": "6.7.0",
"raw-body": "2.3.3", "raw-body": "2.4.0",
"type-is": "~1.6.16" "type-is": "~1.6.17"
}, },
"deprecated": false, "deprecated": false,
"description": "Node.js body parsing middleware", "description": "Node.js body parsing middleware",
"devDependencies": { "devDependencies": {
"eslint": "4.19.1", "eslint": "5.16.0",
"eslint-config-standard": "11.0.0", "eslint-config-standard": "12.0.0",
"eslint-plugin-import": "2.11.0", "eslint-plugin-import": "2.17.2",
"eslint-plugin-markdown": "1.0.0-beta.6", "eslint-plugin-markdown": "1.0.0",
"eslint-plugin-node": "6.0.1", "eslint-plugin-node": "8.0.1",
"eslint-plugin-promise": "3.7.0", "eslint-plugin-promise": "4.1.1",
"eslint-plugin-standard": "3.1.0", "eslint-plugin-standard": "4.0.0",
"istanbul": "0.4.5", "istanbul": "0.4.5",
"methods": "1.1.2", "methods": "1.1.2",
"mocha": "2.5.3", "mocha": "6.1.4",
"safe-buffer": "5.1.2", "safe-buffer": "5.1.2",
"supertest": "1.1.0" "supertest": "4.0.2"
}, },
"engines": { "engines": {
"node": ">= 0.8" "node": ">= 0.8"
@ -87,5 +87,5 @@
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require test/support/env --reporter dot --check-leaks test/", "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require test/support/env --reporter dot --check-leaks test/",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --require test/support/env --reporter spec --check-leaks test/" "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --require test/support/env --reporter spec --check-leaks test/"
}, },
"version": "1.18.3" "version": "1.19.0"
} }

5
node_modules/bytes/History.md generated vendored

@ -1,3 +1,8 @@
3.1.0 / 2019-01-22
==================
* Add petabyte (`pb`) support
3.0.0 / 2017-08-31 3.0.0 / 2017-08-31
================== ==================

13
node_modules/bytes/Readme.md generated vendored

@ -83,6 +83,7 @@ Supported units and abbreviations are as follows and are case-insensitive:
* `mb` for megabytes * `mb` for megabytes
* `gb` for gigabytes * `gb` for gigabytes
* `tb` for terabytes * `tb` for terabytes
* `pb` for petabytes
The units are in powers of two, not ten. This means 1kb = 1024b according to this parser. The units are in powers of two, not ten. This means 1kb = 1024b according to this parser.
@ -108,18 +109,18 @@ bytes('1024');
// output: 1024 // output: 1024
bytes(1024); bytes(1024);
// output: 1024 // output: 1KB
``` ```
## License ## License
[MIT](LICENSE) [MIT](LICENSE)
[downloads-image]: https://img.shields.io/npm/dm/bytes.svg [coveralls-image]: https://badgen.net/coveralls/c/github/visionmedia/bytes.js/master
[coveralls-url]: https://coveralls.io/r/visionmedia/bytes.js?branch=master
[downloads-image]: https://badgen.net/npm/dm/bytes
[downloads-url]: https://npmjs.org/package/bytes [downloads-url]: https://npmjs.org/package/bytes
[npm-image]: https://img.shields.io/npm/v/bytes.svg [npm-image]: https://badgen.net/npm/node/bytes
[npm-url]: https://npmjs.org/package/bytes [npm-url]: https://npmjs.org/package/bytes
[travis-image]: https://img.shields.io/travis/visionmedia/bytes.js/master.svg [travis-image]: https://badgen.net/travis/visionmedia/bytes.js/master
[travis-url]: https://travis-ci.org/visionmedia/bytes.js [travis-url]: https://travis-ci.org/visionmedia/bytes.js
[coveralls-image]: https://img.shields.io/coveralls/visionmedia/bytes.js/master.svg
[coveralls-url]: https://coveralls.io/r/visionmedia/bytes.js?branch=master

9
node_modules/bytes/index.js generated vendored

@ -30,10 +30,11 @@ var map = {
kb: 1 << 10, kb: 1 << 10,
mb: 1 << 20, mb: 1 << 20,
gb: 1 << 30, gb: 1 << 30,
tb: ((1 << 30) * 1024) tb: Math.pow(1024, 4),
pb: Math.pow(1024, 5),
}; };
var parseRegExp = /^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb)$/i; var parseRegExp = /^((-|\+)?(\d+(?:\.\d+)?)) *(kb|mb|gb|tb|pb)$/i;
/** /**
* Convert the given value in bytes into a string or parse to string to an integer in bytes. * Convert the given value in bytes into a string or parse to string to an integer in bytes.
@ -93,7 +94,9 @@ function format(value, options) {
var unit = (options && options.unit) || ''; var unit = (options && options.unit) || '';
if (!unit || !map[unit.toLowerCase()]) { if (!unit || !map[unit.toLowerCase()]) {
if (mag >= map.tb) { if (mag >= map.pb) {
unit = 'PB';
} else if (mag >= map.tb) {
unit = 'TB'; unit = 'TB';
} else if (mag >= map.gb) { } else if (mag >= map.gb) {
unit = 'GB'; unit = 'GB';

28
node_modules/bytes/package.json generated vendored

@ -1,28 +1,28 @@
{ {
"_from": "bytes@3.0.0", "_from": "bytes@3.1.0",
"_id": "bytes@3.0.0", "_id": "bytes@3.1.0",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg=", "_integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==",
"_location": "/bytes", "_location": "/bytes",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "bytes@3.0.0", "raw": "bytes@3.1.0",
"name": "bytes", "name": "bytes",
"escapedName": "bytes", "escapedName": "bytes",
"rawSpec": "3.0.0", "rawSpec": "3.1.0",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "3.0.0" "fetchSpec": "3.1.0"
}, },
"_requiredBy": [ "_requiredBy": [
"/body-parser", "/body-parser",
"/raw-body" "/raw-body"
], ],
"_resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", "_resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz",
"_shasum": "d32815404d689699f85a4ea4fa8755dd13a96048", "_shasum": "f6cf7933a360e0588fa9fde85651cdc7f805d1f6",
"_spec": "bytes@3.0.0", "_spec": "bytes@3.1.0",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/body-parser", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/body-parser",
"author": { "author": {
"name": "TJ Holowaychuk", "name": "TJ Holowaychuk",
"email": "tj@vision-media.ca", "email": "tj@vision-media.ca",
@ -45,8 +45,9 @@
"deprecated": false, "deprecated": false,
"description": "Utility to parse a string bytes to bytes and vice-versa", "description": "Utility to parse a string bytes to bytes and vice-versa",
"devDependencies": { "devDependencies": {
"mocha": "2.5.3", "eslint": "5.12.1",
"nyc": "10.3.2" "mocha": "5.2.0",
"nyc": "13.1.0"
}, },
"engines": { "engines": {
"node": ">= 0.8" "node": ">= 0.8"
@ -74,9 +75,10 @@
"url": "git+https://github.com/visionmedia/bytes.js.git" "url": "git+https://github.com/visionmedia/bytes.js.git"
}, },
"scripts": { "scripts": {
"lint": "eslint .",
"test": "mocha --check-leaks --reporter spec", "test": "mocha --check-leaks --reporter spec",
"test-ci": "nyc --reporter=text npm test", "test-ci": "nyc --reporter=text npm test",
"test-cov": "nyc --reporter=html --reporter=text npm test" "test-cov": "nyc --reporter=html --reporter=text npm test"
}, },
"version": "3.0.0" "version": "3.1.0"
} }

5
node_modules/content-disposition/HISTORY.md generated vendored

@ -1,3 +1,8 @@
0.5.3 / 2018-12-17
==================
* Use `safe-buffer` for improved Buffer API
0.5.2 / 2016-12-08 0.5.2 / 2016-12-08
================== ==================

2
node_modules/content-disposition/LICENSE generated vendored

@ -1,6 +1,6 @@
(The MIT License) (The MIT License)
Copyright (c) 2014 Douglas Christopher Wilson Copyright (c) 2014-2017 Douglas Christopher Wilson
Permission is hereby granted, free of charge, to any person obtaining Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the a copy of this software and associated documentation files (the

23
node_modules/content-disposition/README.md generated vendored

@ -16,6 +16,8 @@ $ npm install content-disposition
## API ## API
<!-- eslint-disable no-unused-vars -->
```js ```js
var contentDisposition = require('content-disposition') var contentDisposition = require('content-disposition')
``` ```
@ -26,6 +28,8 @@ Create an attachment `Content-Disposition` header value using the given file nam
if supplied. The `filename` is optional and if no file name is desired, but you if supplied. The `filename` is optional and if no file name is desired, but you
want to specify `options`, set `filename` to `undefined`. want to specify `options`, set `filename` to `undefined`.
<!-- eslint-disable no-undef -->
```js ```js
res.setHeader('Content-Disposition', contentDisposition('∫ maths.pdf')) res.setHeader('Content-Disposition', contentDisposition('∫ maths.pdf'))
``` ```
@ -66,8 +70,10 @@ it). The type is normalized to lower-case.
### contentDisposition.parse(string) ### contentDisposition.parse(string)
<!-- eslint-disable no-undef, no-unused-vars -->
```js ```js
var disposition = contentDisposition.parse('attachment; filename="EURO rates.txt"; filename*=UTF-8\'\'%e2%82%ac%20rates.txt'); var disposition = contentDisposition.parse('attachment; filename="EURO rates.txt"; filename*=UTF-8\'\'%e2%82%ac%20rates.txt')
``` ```
Parse a `Content-Disposition` header string. This automatically handles extended Parse a `Content-Disposition` header string. This automatically handles extended
@ -88,12 +94,13 @@ are shown for the string `'attachment; filename="EURO rates.txt"; filename*=UTF-
```js ```js
var contentDisposition = require('content-disposition') var contentDisposition = require('content-disposition')
var destroy = require('destroy') var destroy = require('destroy')
var fs = require('fs')
var http = require('http') var http = require('http')
var onFinished = require('on-finished') var onFinished = require('on-finished')
var filePath = '/path/to/public/plans.pdf' var filePath = '/path/to/public/plans.pdf'
http.createServer(function onRequest(req, res) { http.createServer(function onRequest (req, res) {
// set headers // set headers
res.setHeader('Content-Type', 'application/pdf') res.setHeader('Content-Type', 'application/pdf')
res.setHeader('Content-Disposition', contentDisposition(filePath)) res.setHeader('Content-Disposition', contentDisposition(filePath))
@ -101,7 +108,7 @@ http.createServer(function onRequest(req, res) {
// send file // send file
var stream = fs.createReadStream(filePath) var stream = fs.createReadStream(filePath)
stream.pipe(res) stream.pipe(res)
onFinished(res, function (err) { onFinished(res, function () {
destroy(stream) destroy(stream)
}) })
}) })
@ -129,13 +136,13 @@ $ npm test
[MIT](LICENSE) [MIT](LICENSE)
[npm-image]: https://img.shields.io/npm/v/content-disposition.svg?style=flat [npm-image]: https://img.shields.io/npm/v/content-disposition.svg
[npm-url]: https://npmjs.org/package/content-disposition [npm-url]: https://npmjs.org/package/content-disposition
[node-version-image]: https://img.shields.io/node/v/content-disposition.svg?style=flat [node-version-image]: https://img.shields.io/node/v/content-disposition.svg
[node-version-url]: https://nodejs.org/en/download [node-version-url]: https://nodejs.org/en/download
[travis-image]: https://img.shields.io/travis/jshttp/content-disposition.svg?style=flat [travis-image]: https://img.shields.io/travis/jshttp/content-disposition.svg
[travis-url]: https://travis-ci.org/jshttp/content-disposition [travis-url]: https://travis-ci.org/jshttp/content-disposition
[coveralls-image]: https://img.shields.io/coveralls/jshttp/content-disposition.svg?style=flat [coveralls-image]: https://img.shields.io/coveralls/jshttp/content-disposition.svg
[coveralls-url]: https://coveralls.io/r/jshttp/content-disposition?branch=master [coveralls-url]: https://coveralls.io/r/jshttp/content-disposition?branch=master
[downloads-image]: https://img.shields.io/npm/dm/content-disposition.svg?style=flat [downloads-image]: https://img.shields.io/npm/dm/content-disposition.svg
[downloads-url]: https://npmjs.org/package/content-disposition [downloads-url]: https://npmjs.org/package/content-disposition

47
node_modules/content-disposition/index.js generated vendored

@ -1,6 +1,6 @@
/*! /*!
* content-disposition * content-disposition
* Copyright(c) 2014 Douglas Christopher Wilson * Copyright(c) 2014-2017 Douglas Christopher Wilson
* MIT Licensed * MIT Licensed
*/ */
@ -8,6 +8,7 @@
/** /**
* Module exports. * Module exports.
* @public
*/ */
module.exports = contentDisposition module.exports = contentDisposition
@ -15,18 +16,22 @@ module.exports.parse = parse
/** /**
* Module dependencies. * Module dependencies.
* @private
*/ */
var basename = require('path').basename var basename = require('path').basename
var Buffer = require('safe-buffer').Buffer
/** /**
* RegExp to match non attr-char, *after* encodeURIComponent (i.e. not including "%") * RegExp to match non attr-char, *after* encodeURIComponent (i.e. not including "%")
* @private
*/ */
var ENCODE_URL_ATTR_CHAR_REGEXP = /[\x00-\x20"'()*,/:;<=>?@[\\\]{}\x7f]/g // eslint-disable-line no-control-regex var ENCODE_URL_ATTR_CHAR_REGEXP = /[\x00-\x20"'()*,/:;<=>?@[\\\]{}\x7f]/g // eslint-disable-line no-control-regex
/** /**
* RegExp to match percent encoding escape. * RegExp to match percent encoding escape.
* @private
*/ */
var HEX_ESCAPE_REGEXP = /%[0-9A-Fa-f]{2}/ var HEX_ESCAPE_REGEXP = /%[0-9A-Fa-f]{2}/
@ -34,6 +39,7 @@ var HEX_ESCAPE_REPLACE_REGEXP = /%([0-9A-Fa-f]{2})/g
/** /**
* RegExp to match non-latin1 characters. * RegExp to match non-latin1 characters.
* @private
*/ */
var NON_LATIN1_REGEXP = /[^\x20-\x7e\xa0-\xff]/g var NON_LATIN1_REGEXP = /[^\x20-\x7e\xa0-\xff]/g
@ -43,12 +49,14 @@ var NON_LATIN1_REGEXP = /[^\x20-\x7e\xa0-\xff]/g
* *
* quoted-pair = "\" CHAR * quoted-pair = "\" CHAR
* CHAR = <any US-ASCII character (octets 0 - 127)> * CHAR = <any US-ASCII character (octets 0 - 127)>
* @private
*/ */
var QESC_REGEXP = /\\([\u0000-\u007f])/g var QESC_REGEXP = /\\([\u0000-\u007f])/g // eslint-disable-line no-control-regex
/** /**
* RegExp to match chars that must be quoted-pair in RFC 2616 * RegExp to match chars that must be quoted-pair in RFC 2616
* @private
*/ */
var QUOTE_REGEXP = /([\\"])/g var QUOTE_REGEXP = /([\\"])/g
@ -75,6 +83,7 @@ var QUOTE_REGEXP = /([\\"])/g
* HT = <US-ASCII HT, horizontal-tab (9)> * HT = <US-ASCII HT, horizontal-tab (9)>
* CTL = <any US-ASCII control character (octets 0 - 31) and DEL (127)> * CTL = <any US-ASCII control character (octets 0 - 31) and DEL (127)>
* OCTET = <any 8-bit sequence of data> * OCTET = <any 8-bit sequence of data>
* @private
*/ */
var PARAM_REGEXP = /;[\x09\x20]*([!#$%&'*+.0-9A-Z^_`a-z|~-]+)[\x09\x20]*=[\x09\x20]*("(?:[\x20!\x23-\x5b\x5d-\x7e\x80-\xff]|\\[\x20-\x7e])*"|[!#$%&'*+.0-9A-Z^_`a-z|~-]+)[\x09\x20]*/g // eslint-disable-line no-control-regex var PARAM_REGEXP = /;[\x09\x20]*([!#$%&'*+.0-9A-Z^_`a-z|~-]+)[\x09\x20]*=[\x09\x20]*("(?:[\x20!\x23-\x5b\x5d-\x7e\x80-\xff]|\\[\x20-\x7e])*"|[!#$%&'*+.0-9A-Z^_`a-z|~-]+)[\x09\x20]*/g // eslint-disable-line no-control-regex
@ -100,6 +109,7 @@ var TOKEN_REGEXP = /^[!#$%&'*+.0-9A-Z^_`a-z|~-]+$/
* attr-char = ALPHA / DIGIT * attr-char = ALPHA / DIGIT
* / "!" / "#" / "$" / "&" / "+" / "-" / "." * / "!" / "#" / "$" / "&" / "+" / "-" / "."
* / "^" / "_" / "`" / "|" / "~" * / "^" / "_" / "`" / "|" / "~"
* @private
*/ */
var EXT_VALUE_REGEXP = /^([A-Za-z0-9!#$%&+\-^_`{}~]+)'(?:[A-Za-z]{2,3}(?:-[A-Za-z]{3}){0,3}|[A-Za-z]{4,8}|)'((?:%[0-9A-Fa-f]{2}|[A-Za-z0-9!#$&+.^_`|~-])+)$/ var EXT_VALUE_REGEXP = /^([A-Za-z0-9!#$%&+\-^_`{}~]+)'(?:[A-Za-z]{2,3}(?:-[A-Za-z]{3}){0,3}|[A-Za-z]{4,8}|)'((?:%[0-9A-Fa-f]{2}|[A-Za-z0-9!#$&+.^_`|~-])+)$/
@ -115,6 +125,7 @@ var EXT_VALUE_REGEXP = /^([A-Za-z0-9!#$%&+\-^_`{}~]+)'(?:[A-Za-z]{2,3}(?:-[A-Za-
* disp-ext-parm = token "=" value * disp-ext-parm = token "=" value
* | ext-token "=" ext-value * | ext-token "=" ext-value
* ext-token = <the characters in token, followed by "*"> * ext-token = <the characters in token, followed by "*">
* @private
*/ */
var DISPOSITION_TYPE_REGEXP = /^([!#$%&'*+.0-9A-Z^_`a-z|~-]+)[\x09\x20]*(?:$|;)/ // eslint-disable-line no-control-regex var DISPOSITION_TYPE_REGEXP = /^([!#$%&'*+.0-9A-Z^_`a-z|~-]+)[\x09\x20]*(?:$|;)/ // eslint-disable-line no-control-regex
@ -127,7 +138,7 @@ var DISPOSITION_TYPE_REGEXP = /^([!#$%&'*+.0-9A-Z^_`a-z|~-]+)[\x09\x20]*(?:$|;)/
* @param {string} [options.type=attachment] * @param {string} [options.type=attachment]
* @param {string|boolean} [options.fallback=true] * @param {string|boolean} [options.fallback=true]
* @return {string} * @return {string}
* @api public * @public
*/ */
function contentDisposition (filename, options) { function contentDisposition (filename, options) {
@ -149,7 +160,7 @@ function contentDisposition (filename, options) {
* @param {string} [filename] * @param {string} [filename]
* @param {string|boolean} [fallback=true] * @param {string|boolean} [fallback=true]
* @return {object} * @return {object}
* @api private * @private
*/ */
function createparams (filename, fallback) { function createparams (filename, fallback) {
@ -210,7 +221,7 @@ function createparams (filename, fallback) {
* @param {string} obj.type * @param {string} obj.type
* @param {object} [obj.parameters] * @param {object} [obj.parameters]
* @return {string} * @return {string}
* @api private * @private
*/ */
function format (obj) { function format (obj) {
@ -248,7 +259,7 @@ function format (obj) {
* *
* @param {string} str * @param {string} str
* @return {string} * @return {string}
* @api private * @private
*/ */
function decodefield (str) { function decodefield (str) {
@ -270,7 +281,7 @@ function decodefield (str) {
value = getlatin1(binary) value = getlatin1(binary)
break break
case 'utf-8': case 'utf-8':
value = new Buffer(binary, 'binary').toString('utf8') value = Buffer.from(binary, 'binary').toString('utf8')
break break
default: default:
throw new TypeError('unsupported charset in extended field') throw new TypeError('unsupported charset in extended field')
@ -284,7 +295,7 @@ function decodefield (str) {
* *
* @param {string} val * @param {string} val
* @return {string} * @return {string}
* @api private * @private
*/ */
function getlatin1 (val) { function getlatin1 (val) {
@ -297,7 +308,7 @@ function getlatin1 (val) {
* *
* @param {string} string * @param {string} string
* @return {object} * @return {object}
* @api private * @public
*/ */
function parse (string) { function parse (string) {
@ -378,7 +389,7 @@ function parse (string) {
* @param {string} str * @param {string} str
* @param {string} hex * @param {string} hex
* @return {string} * @return {string}
* @api private * @private
*/ */
function pdecode (str, hex) { function pdecode (str, hex) {
@ -390,17 +401,14 @@ function pdecode (str, hex) {
* *
* @param {string} char * @param {string} char
* @return {string} * @return {string}
* @api private * @private
*/ */
function pencode (char) { function pencode (char) {
var hex = String(char) return '%' + String(char)
.charCodeAt(0) .charCodeAt(0)
.toString(16) .toString(16)
.toUpperCase() .toUpperCase()
return hex.length === 1
? '%0' + hex
: '%' + hex
} }
/** /**
@ -408,7 +416,7 @@ function pencode (char) {
* *
* @param {string} val * @param {string} val
* @return {string} * @return {string}
* @api private * @private
*/ */
function qstring (val) { function qstring (val) {
@ -422,7 +430,7 @@ function qstring (val) {
* *
* @param {string} val * @param {string} val
* @return {string} * @return {string}
* @api private * @private
*/ */
function ustring (val) { function ustring (val) {
@ -437,6 +445,11 @@ function ustring (val) {
/** /**
* Class for parsed Content-Disposition header for v8 optimization * Class for parsed Content-Disposition header for v8 optimization
*
* @public
* @param {string} type
* @param {object} parameters
* @constructor
*/ */
function ContentDisposition (type, parameters) { function ContentDisposition (type, parameters) {

51
node_modules/content-disposition/package.json generated vendored

@ -1,46 +1,51 @@
{ {
"_from": "content-disposition@0.5.2", "_from": "content-disposition@0.5.3",
"_id": "content-disposition@0.5.2", "_id": "content-disposition@0.5.3",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha1-DPaLud318r55YcOoUXjLhdunjLQ=", "_integrity": "sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==",
"_location": "/content-disposition", "_location": "/content-disposition",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "content-disposition@0.5.2", "raw": "content-disposition@0.5.3",
"name": "content-disposition", "name": "content-disposition",
"escapedName": "content-disposition", "escapedName": "content-disposition",
"rawSpec": "0.5.2", "rawSpec": "0.5.3",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "0.5.2" "fetchSpec": "0.5.3"
}, },
"_requiredBy": [ "_requiredBy": [
"/express" "/express"
], ],
"_resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.2.tgz", "_resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz",
"_shasum": "0cf68bb9ddf5f2be7961c3a85178cb85dba78cb4", "_shasum": "e130caf7e7279087c5616c2007d0485698984fbd",
"_spec": "content-disposition@0.5.2", "_spec": "content-disposition@0.5.3",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"author": {
"name": "Douglas Christopher Wilson",
"email": "doug@somethingdoug.com"
},
"bugs": { "bugs": {
"url": "https://github.com/jshttp/content-disposition/issues" "url": "https://github.com/jshttp/content-disposition/issues"
}, },
"bundleDependencies": false, "bundleDependencies": false,
"contributors": [ "dependencies": {
{ "safe-buffer": "5.1.2"
"name": "Douglas Christopher Wilson", },
"email": "doug@somethingdoug.com"
}
],
"deprecated": false, "deprecated": false,
"description": "Create and parse Content-Disposition header", "description": "Create and parse Content-Disposition header",
"devDependencies": { "devDependencies": {
"eslint": "3.11.1", "deep-equal": "1.0.1",
"eslint-config-standard": "6.2.1", "eslint": "5.10.0",
"eslint-plugin-promise": "3.3.0", "eslint-config-standard": "12.0.0",
"eslint-plugin-standard": "2.0.1", "eslint-plugin-import": "2.14.0",
"eslint-plugin-markdown": "1.0.0-rc.1",
"eslint-plugin-node": "7.0.1",
"eslint-plugin-promise": "4.0.1",
"eslint-plugin-standard": "4.0.0",
"istanbul": "0.4.5", "istanbul": "0.4.5",
"mocha": "1.21.5" "mocha": "5.2.0"
}, },
"engines": { "engines": {
"node": ">= 0.6" "node": ">= 0.6"
@ -65,10 +70,10 @@
"url": "git+https://github.com/jshttp/content-disposition.git" "url": "git+https://github.com/jshttp/content-disposition.git"
}, },
"scripts": { "scripts": {
"lint": "eslint .", "lint": "eslint --plugin markdown --ext js,md .",
"test": "mocha --reporter spec --bail --check-leaks test/", "test": "mocha --reporter spec --bail --check-leaks test/",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/", "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/" "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
}, },
"version": "0.5.2" "version": "0.5.3"
} }

2
node_modules/content-type/package.json generated vendored

@ -22,7 +22,7 @@
"_resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz", "_resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz",
"_shasum": "e138cc75e040c727b1966fe5e5f8c9aee256fe3b", "_shasum": "e138cc75e040c727b1966fe5e5f8c9aee256fe3b",
"_spec": "content-type@~1.0.4", "_spec": "content-type@~1.0.4",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"author": { "author": {
"name": "Douglas Christopher Wilson", "name": "Douglas Christopher Wilson",
"email": "doug@somethingdoug.com" "email": "doug@somethingdoug.com"

7
node_modules/cookie-parser/HISTORY.md generated vendored

@ -1,3 +1,8 @@
1.4.5 / 2020-03-14
==================
* deps: cookie@0.4.0
1.4.4 / 2019-02-12 1.4.4 / 2019-02-12
================== ==================
@ -15,7 +20,7 @@
* deps: cookie@0.2.4 * deps: cookie@0.2.4
- perf: enable strict mode - perf: enable strict mode
- perf: use for loop in parse - perf: use for loop in parse
- perf: use string concatination for serialization - perf: use string concatenation for serialization
1.4.1 / 2016-01-11 1.4.1 / 2016-01-11
================== ==================

39
node_modules/cookie-parser/README.md generated vendored

@ -5,9 +5,10 @@
[![Build Status][travis-image]][travis-url] [![Build Status][travis-image]][travis-url]
[![Test Coverage][coveralls-image]][coveralls-url] [![Test Coverage][coveralls-image]][coveralls-url]
Parse `Cookie` header and populate `req.cookies` with an object keyed by the cookie Parse `Cookie` header and populate `req.cookies` with an object keyed by the
names. Optionally you may enable signed cookie support by passing a `secret` string, cookie names. Optionally you may enable signed cookie support by passing a
which assigns `req.secret` so it may be used by other middleware. `secret` string, which assigns `req.secret` so it may be used by other
middleware.
## Installation ## Installation
@ -27,29 +28,45 @@ app.use(cookieParser())
### cookieParser(secret, options) ### cookieParser(secret, options)
- `secret` a string or array used for signing cookies. This is optional and if not specified, will not parse signed cookies. If a string is provided, this is used as the secret. If an array is provided, an attempt will be made to unsign the cookie with each secret in order. - `secret` a string or array used for signing cookies. This is optional and if
- `options` an object that is passed to `cookie.parse` as the second option. See [cookie](https://www.npmjs.org/package/cookie) for more information. not specified, will not parse signed cookies. If a string is provided, this
is used as the secret. If an array is provided, an attempt will be made to
unsign the cookie with each secret in order.
- `options` an object that is passed to `cookie.parse` as the second option. Se
[cookie](https://www.npmjs.org/package/cookie) for more information.
- `decode` a function to decode the value of the cookie - `decode` a function to decode the value of the cookie
### cookieParser.JSONCookie(str) ### cookieParser.JSONCookie(str)
Parse a cookie value as a JSON cookie. This will return the parsed JSON value if it was a JSON cookie, otherwise it will return the passed value. Parse a cookie value as a JSON cookie. This will return the parsed JSON value
if it was a JSON cookie, otherwise, it will return the passed value.
### cookieParser.JSONCookies(cookies) ### cookieParser.JSONCookies(cookies)
Given an object, this will iterate over the keys and call `JSONCookie` on each value, replacing the original value with the parsed value. This returns the same object that was passed in. Given an object, this will iterate over the keys and call `JSONCookie` on each
value, replacing the original value with the parsed value. This returns the
same object that was passed in.
### cookieParser.signedCookie(str, secret) ### cookieParser.signedCookie(str, secret)
Parse a cookie value as a signed cookie. This will return the parsed unsigned value if it was a signed cookie and the signature was valid. If the value was not signed, the original value is returned. If the value was signed but the signature could not be validated, `false` is returned. Parse a cookie value as a signed cookie. This will return the parsed unsigned
value if it was a signed cookie and the signature was valid. If the value was
not signed, the original value is returned. If the value was signed but the
signature could not be validated, `false` is returned.
The `secret` argument can be an array or string. If a string is provided, this is used as the secret. If an array is provided, an attempt will be made to unsign the cookie with each secret in order. The `secret` argument can be an array or string. If a string is provided, this
is used as the secret. If an array is provided, an attempt will be made to
unsign the cookie with each secret in order.
### cookieParser.signedCookies(cookies, secret) ### cookieParser.signedCookies(cookies, secret)
Given an object, this will iterate over the keys and check if any value is a signed cookie. If it is a signed cookie and the signature is valid, the key will be deleted from the object and added to the new object that is returned. Given an object, this will iterate over the keys and check if any value is a
signed cookie. If it is a signed cookie and the signature is valid, the key
will be deleted from the object and added to the new object that is returned.
The `secret` argument can be an array or string. If a string is provided, this is used as the secret. If an array is provided, an attempt will be made to unsign the cookie with each secret in order. The `secret` argument can be an array or string. If a string is provided, this
is used as the secret. If an array is provided, an attempt will be made to
unsign the cookie with each secret in order.
## Example ## Example

43
node_modules/cookie-parser/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "cookie-parser@~1.4.4", "_from": "cookie-parser@^1.4.5",
"_id": "cookie-parser@1.4.4", "_id": "cookie-parser@1.4.5",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-lo13tqF3JEtFO7FyA49CqbhaFkskRJ0u/UAiINgrIXeRCY41c88/zxtrECl8AKH3B0hj9q10+h3Kt8I7KlW4tw==", "_integrity": "sha512-f13bPUj/gG/5mDr+xLmSxxDsB9DQiTIfhJS/sqjrmfAWiAN+x2O4i/XguTL9yDZ+/IFDanJ+5x7hC4CXT9Tdzw==",
"_location": "/cookie-parser", "_location": "/cookie-parser",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "cookie-parser@~1.4.4", "raw": "cookie-parser@^1.4.5",
"name": "cookie-parser", "name": "cookie-parser",
"escapedName": "cookie-parser", "escapedName": "cookie-parser",
"rawSpec": "~1.4.4", "rawSpec": "^1.4.5",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~1.4.4" "fetchSpec": "^1.4.5"
}, },
"_requiredBy": [ "_requiredBy": [
"/" "/"
], ],
"_resolved": "https://registry.npmjs.org/cookie-parser/-/cookie-parser-1.4.4.tgz", "_resolved": "https://registry.npmjs.org/cookie-parser/-/cookie-parser-1.4.5.tgz",
"_shasum": "e6363de4ea98c3def9697b93421c09f30cf5d188", "_shasum": "3e572d4b7c0c80f9c61daf604e4336831b5d1d49",
"_spec": "cookie-parser@~1.4.4", "_spec": "cookie-parser@^1.4.5",
"_where": "/home/f2256342/forge/es6-nodejs", "_where": "/home/yutsuo/forge/nodejs/es6-express",
"author": { "author": {
"name": "TJ Holowaychuk", "name": "TJ Holowaychuk",
"email": "tj@vision-media.ca", "email": "tj@vision-media.ca",
@ -38,23 +38,22 @@
} }
], ],
"dependencies": { "dependencies": {
"cookie": "0.3.1", "cookie": "0.4.0",
"cookie-signature": "1.0.6" "cookie-signature": "1.0.6"
}, },
"deprecated": false, "deprecated": false,
"description": "Parse HTTP request cookies", "description": "Parse HTTP request cookies",
"devDependencies": { "devDependencies": {
"deep-equal": "1.0.1", "eslint": "6.8.0",
"eslint": "5.13.0", "eslint-config-standard": "14.1.0",
"eslint-config-standard": "12.0.0", "eslint-plugin-import": "2.20.1",
"eslint-plugin-import": "2.16.0", "eslint-plugin-markdown": "1.0.2",
"eslint-plugin-markdown": "1.0.0", "eslint-plugin-node": "11.0.0",
"eslint-plugin-node": "7.0.1", "eslint-plugin-promise": "4.2.1",
"eslint-plugin-promise": "4.0.1", "eslint-plugin-standard": "4.0.1",
"eslint-plugin-standard": "4.0.0",
"istanbul": "0.4.5", "istanbul": "0.4.5",
"mocha": "5.2.0", "mocha": "7.1.0",
"supertest": "3.4.2" "supertest": "4.0.2"
}, },
"engines": { "engines": {
"node": ">= 0.8.0" "node": ">= 0.8.0"
@ -81,5 +80,5 @@
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/", "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/" "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
}, },
"version": "1.4.4" "version": "1.4.5"
} }

2
node_modules/cookie-signature/package.json generated vendored

@ -22,7 +22,7 @@
"_resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", "_resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz",
"_shasum": "e303a882b342cc3ee8ca513a79999734dab3ae2c", "_shasum": "e303a882b342cc3ee8ca513a79999734dab3ae2c",
"_spec": "cookie-signature@1.0.6", "_spec": "cookie-signature@1.0.6",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/cookie-parser", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/cookie-parser",
"author": { "author": {
"name": "TJ Holowaychuk", "name": "TJ Holowaychuk",
"email": "tj@learnboost.com" "email": "tj@learnboost.com"

5
node_modules/cookie/HISTORY.md generated vendored

@ -1,3 +1,8 @@
0.4.0 / 2019-05-15
==================
* Add `SameSite=None` support
0.3.1 / 2016-05-26 0.3.1 / 2016-05-26
================== ==================

109
node_modules/cookie/README.md generated vendored

@ -1,7 +1,7 @@
# cookie # cookie
[![NPM Version][npm-image]][npm-url] [![NPM Version][npm-version-image]][npm-url]
[![NPM Downloads][downloads-image]][downloads-url] [![NPM Downloads][npm-downloads-image]][npm-url]
[![Node.js Version][node-version-image]][node-version-url] [![Node.js Version][node-version-image]][node-version-url]
[![Build Status][travis-image]][travis-url] [![Build Status][travis-image]][travis-url]
[![Test Coverage][coveralls-image]][coveralls-url] [![Test Coverage][coveralls-image]][coveralls-url]
@ -64,7 +64,7 @@ var setCookie = cookie.serialize('foo', 'bar');
##### domain ##### domain
Specifies the value for the [`Domain` `Set-Cookie` attribute][rfc-6266-5.2.3]. By default, no Specifies the value for the [`Domain` `Set-Cookie` attribute][rfc-6265-5.2.3]. By default, no
domain is set, and most clients will consider the cookie to apply to only the current domain. domain is set, and most clients will consider the cookie to apply to only the current domain.
##### encode ##### encode
@ -73,22 +73,22 @@ Specifies a function that will be used to encode a cookie's value. Since value o
has a limited character set (and must be a simple string), this function can be used to encode has a limited character set (and must be a simple string), this function can be used to encode
a value into a string suited for a cookie's value. a value into a string suited for a cookie's value.
The default function is the global `ecodeURIComponent`, which will encode a JavaScript string The default function is the global `encodeURIComponent`, which will encode a JavaScript string
into UTF-8 byte sequences and then URL-encode any that fall outside of the cookie range. into UTF-8 byte sequences and then URL-encode any that fall outside of the cookie range.
##### expires ##### expires
Specifies the `Date` object to be the value for the [`Expires` `Set-Cookie` attribute][rfc-6266-5.2.1]. Specifies the `Date` object to be the value for the [`Expires` `Set-Cookie` attribute][rfc-6265-5.2.1].
By default, no expiration is set, and most clients will consider this a "non-persistent cookie" and By default, no expiration is set, and most clients will consider this a "non-persistent cookie" and
will delete it on a condition like exiting a web browser application. will delete it on a condition like exiting a web browser application.
**note** the [cookie storage model specification][rfc-6266-5.3] states that if both `expires` and **note** the [cookie storage model specification][rfc-6265-5.3] states that if both `expires` and
`magAge` are set, then `maxAge` takes precedence, but it is possiblke not all clients by obey this, `maxAge` are set, then `maxAge` takes precedence, but it is possible not all clients by obey this,
so if both are set, they should point to the same date and time. so if both are set, they should point to the same date and time.
##### httpOnly ##### httpOnly
Specifies the `boolean` value for the [`HttpOnly` `Set-Cookie` attribute][rfc-6266-5.2.6]. When truthy, Specifies the `boolean` value for the [`HttpOnly` `Set-Cookie` attribute][rfc-6265-5.2.6]. When truthy,
the `HttpOnly` attribute is set, otherwise it is not. By default, the `HttpOnly` attribute is not set. the `HttpOnly` attribute is set, otherwise it is not. By default, the `HttpOnly` attribute is not set.
**note** be careful when setting this to `true`, as compliant clients will not allow client-side **note** be careful when setting this to `true`, as compliant clients will not allow client-side
@ -96,38 +96,37 @@ JavaScript to see the cookie in `document.cookie`.
##### maxAge ##### maxAge
Specifies the `number` (in seconds) to be the value for the [`Max-Age` `Set-Cookie` attribute][rfc-6266-5.2.2]. Specifies the `number` (in seconds) to be the value for the [`Max-Age` `Set-Cookie` attribute][rfc-6265-5.2.2].
The given number will be converted to an integer by rounding down. By default, no maximum age is set. The given number will be converted to an integer by rounding down. By default, no maximum age is set.
**note** the [cookie storage model specification][rfc-6266-5.3] states that if both `expires` and **note** the [cookie storage model specification][rfc-6265-5.3] states that if both `expires` and
`magAge` are set, then `maxAge` takes precedence, but it is possiblke not all clients by obey this, `maxAge` are set, then `maxAge` takes precedence, but it is possible not all clients by obey this,
so if both are set, they should point to the same date and time. so if both are set, they should point to the same date and time.
##### path ##### path
Specifies the value for the [`Path` `Set-Cookie` attribute][rfc-6266-5.2.4]. By default, the path Specifies the value for the [`Path` `Set-Cookie` attribute][rfc-6265-5.2.4]. By default, the path
is considered the ["default path"][rfc-6266-5.1.4]. By default, no maximum age is set, and most is considered the ["default path"][rfc-6265-5.1.4].
clients will consider this a "non-persistent cookie" and will delete it on a condition like exiting
a web browser application.
##### sameSite ##### sameSite
Specifies the `boolean` or `string` to be the value for the [`SameSite` `Set-Cookie` attribute][draft-west-first-party-cookies-07]. Specifies the `boolean` or `string` to be the value for the [`SameSite` `Set-Cookie` attribute][rfc-6265bis-03-4.1.2.7].
- `true` will set the `SameSite` attribute to `Strict` for strict same site enforcement. - `true` will set the `SameSite` attribute to `Strict` for strict same site enforcement.
- `false` will not set the `SameSite` attribute. - `false` will not set the `SameSite` attribute.
- `'lax'` will set the `SameSite` attribute to `Lax` for lax same site enforcement. - `'lax'` will set the `SameSite` attribute to `Lax` for lax same site enforcement.
- `'none'` will set the `SameSite` attribute to `None` for an explicit cross-site cookie.
- `'strict'` will set the `SameSite` attribute to `Strict` for strict same site enforcement. - `'strict'` will set the `SameSite` attribute to `Strict` for strict same site enforcement.
More information about the different enforcement levels can be found in the specification More information about the different enforcement levels can be found in
https://tools.ietf.org/html/draft-west-first-party-cookies-07#section-4.1.1 [the specification][rfc-6265bis-03-4.1.2.7].
**note** This is an attribute that has not yet been fully standardized, and may change in the future. **note** This is an attribute that has not yet been fully standardized, and may change in the future.
This also means many clients may ignore this attribute until they understand it. This also means many clients may ignore this attribute until they understand it.
##### secure ##### secure
Specifies the `boolean` value for the [`Secure` `Set-Cookie` attribute][rfc-6266-5.2.5]. When truthy, Specifies the `boolean` value for the [`Secure` `Set-Cookie` attribute][rfc-6265-5.2.5]. When truthy,
the `Secure` attribute is set, otherwise it is not. By default, the `Secure` attribute is not set. the `Secure` attribute is set, otherwise it is not. By default, the `Secure` attribute is not set.
**note** be careful when setting this to `true`, as compliant clients will not send the cookie back to **note** be careful when setting this to `true`, as compliant clients will not send the cookie back to
@ -178,7 +177,7 @@ function onRequest(req, res) {
res.write('<form method="GET">'); res.write('<form method="GET">');
res.write('<input placeholder="enter your name" name="name"> <input type="submit" value="Set Name">'); res.write('<input placeholder="enter your name" name="name"> <input type="submit" value="Set Name">');
res.end('</form'); res.end('</form>');
} }
http.createServer(onRequest).listen(3000); http.createServer(onRequest).listen(3000);
@ -190,31 +189,65 @@ http.createServer(onRequest).listen(3000);
$ npm test $ npm test
``` ```
## Benchmark
```
$ npm run bench
> cookie@0.3.1 bench cookie
> node benchmark/index.js
http_parser@2.8.0
node@6.14.2
v8@5.1.281.111
uv@1.16.1
zlib@1.2.11
ares@1.10.1-DEV
icu@58.2
modules@48
napi@3
openssl@1.0.2o
> node benchmark/parse.js
cookie.parse
6 tests completed.
simple x 1,200,691 ops/sec ±1.12% (189 runs sampled)
decode x 1,012,994 ops/sec ±0.97% (186 runs sampled)
unquote x 1,074,174 ops/sec ±2.43% (186 runs sampled)
duplicates x 438,424 ops/sec ±2.17% (184 runs sampled)
10 cookies x 147,154 ops/sec ±1.01% (186 runs sampled)
100 cookies x 14,274 ops/sec ±1.07% (187 runs sampled)
```
## References ## References
- [RFC 6266: HTTP State Management Mechanism][rfc-6266] - [RFC 6265: HTTP State Management Mechanism][rfc-6265]
- [Same-site Cookies][draft-west-first-party-cookies-07] - [Same-site Cookies][rfc-6265bis-03-4.1.2.7]
[draft-west-first-party-cookies-07]: https://tools.ietf.org/html/draft-west-first-party-cookies-07 [rfc-6265bis-03-4.1.2.7]: https://tools.ietf.org/html/draft-ietf-httpbis-rfc6265bis-03#section-4.1.2.7
[rfc-6266]: https://tools.ietf.org/html/rfc6266 [rfc-6265]: https://tools.ietf.org/html/rfc6265
[rfc-6266-5.1.4]: https://tools.ietf.org/html/rfc6266#section-5.1.4 [rfc-6265-5.1.4]: https://tools.ietf.org/html/rfc6265#section-5.1.4
[rfc-6266-5.2.1]: https://tools.ietf.org/html/rfc6266#section-5.2.1 [rfc-6265-5.2.1]: https://tools.ietf.org/html/rfc6265#section-5.2.1
[rfc-6266-5.2.2]: https://tools.ietf.org/html/rfc6266#section-5.2.2 [rfc-6265-5.2.2]: https://tools.ietf.org/html/rfc6265#section-5.2.2
[rfc-6266-5.2.3]: https://tools.ietf.org/html/rfc6266#section-5.2.3 [rfc-6265-5.2.3]: https://tools.ietf.org/html/rfc6265#section-5.2.3
[rfc-6266-5.2.4]: https://tools.ietf.org/html/rfc6266#section-5.2.4 [rfc-6265-5.2.4]: https://tools.ietf.org/html/rfc6265#section-5.2.4
[rfc-6266-5.3]: https://tools.ietf.org/html/rfc6266#section-5.3 [rfc-6265-5.2.5]: https://tools.ietf.org/html/rfc6265#section-5.2.5
[rfc-6265-5.2.6]: https://tools.ietf.org/html/rfc6265#section-5.2.6
[rfc-6265-5.3]: https://tools.ietf.org/html/rfc6265#section-5.3
## License ## License
[MIT](LICENSE) [MIT](LICENSE)
[npm-image]: https://img.shields.io/npm/v/cookie.svg [coveralls-image]: https://badgen.net/coveralls/c/github/jshttp/cookie/master
[npm-url]: https://npmjs.org/package/cookie [coveralls-url]: https://coveralls.io/r/jshttp/cookie?branch=master
[node-version-image]: https://img.shields.io/node/v/cookie.svg [node-version-image]: https://badgen.net/npm/node/cookie
[node-version-url]: https://nodejs.org/en/download [node-version-url]: https://nodejs.org/en/download
[travis-image]: https://img.shields.io/travis/jshttp/cookie/master.svg [npm-downloads-image]: https://badgen.net/npm/dm/cookie
[npm-url]: https://npmjs.org/package/cookie
[npm-version-image]: https://badgen.net/npm/v/cookie
[travis-image]: https://badgen.net/travis/jshttp/cookie/master
[travis-url]: https://travis-ci.org/jshttp/cookie [travis-url]: https://travis-ci.org/jshttp/cookie
[coveralls-image]: https://img.shields.io/coveralls/jshttp/cookie/master.svg
[coveralls-url]: https://coveralls.io/r/jshttp/cookie?branch=master
[downloads-image]: https://img.shields.io/npm/dm/cookie.svg
[downloads-url]: https://npmjs.org/package/cookie

3
node_modules/cookie/index.js generated vendored

@ -170,6 +170,9 @@ function serialize(name, val, options) {
case 'strict': case 'strict':
str += '; SameSite=Strict'; str += '; SameSite=Strict';
break; break;
case 'none':
str += '; SameSite=None';
break;
default: default:
throw new TypeError('option sameSite is invalid'); throw new TypeError('option sameSite is invalid');
} }

35
node_modules/cookie/package.json generated vendored

@ -1,28 +1,28 @@
{ {
"_from": "cookie@0.3.1", "_from": "cookie@0.4.0",
"_id": "cookie@0.3.1", "_id": "cookie@0.4.0",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha1-5+Ch+e9DtMi6klxcWpboBtFoc7s=", "_integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==",
"_location": "/cookie", "_location": "/cookie",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "cookie@0.3.1", "raw": "cookie@0.4.0",
"name": "cookie", "name": "cookie",
"escapedName": "cookie", "escapedName": "cookie",
"rawSpec": "0.3.1", "rawSpec": "0.4.0",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "0.3.1" "fetchSpec": "0.4.0"
}, },
"_requiredBy": [ "_requiredBy": [
"/cookie-parser", "/cookie-parser",
"/express" "/express"
], ],
"_resolved": "https://registry.npmjs.org/cookie/-/cookie-0.3.1.tgz", "_resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz",
"_shasum": "e7e0a1f9ef43b4c8ba925c5c5a96e806d16873bb", "_shasum": "beb437e7022b3b6d49019d088665303ebe9c14ba",
"_spec": "cookie@0.3.1", "_spec": "cookie@0.4.0",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/cookie-parser", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/cookie-parser",
"author": { "author": {
"name": "Roman Shtylman", "name": "Roman Shtylman",
"email": "shtylman@gmail.com" "email": "shtylman@gmail.com"
@ -40,8 +40,12 @@
"deprecated": false, "deprecated": false,
"description": "HTTP server cookie parsing and serialization", "description": "HTTP server cookie parsing and serialization",
"devDependencies": { "devDependencies": {
"istanbul": "0.4.3", "beautify-benchmark": "0.2.4",
"mocha": "1.21.5" "benchmark": "2.1.4",
"eslint": "5.16.0",
"eslint-plugin-markdown": "1.0.0",
"istanbul": "0.4.5",
"mocha": "6.1.4"
}, },
"engines": { "engines": {
"node": ">= 0.6" "node": ">= 0.6"
@ -64,9 +68,12 @@
"url": "git+https://github.com/jshttp/cookie.git" "url": "git+https://github.com/jshttp/cookie.git"
}, },
"scripts": { "scripts": {
"bench": "node benchmark/index.js",
"lint": "eslint --plugin markdown --ext js,md .",
"test": "mocha --reporter spec --bail --check-leaks test/", "test": "mocha --reporter spec --bail --check-leaks test/",
"test-ci": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/", "test-ci": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/" "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
"version": "node scripts/version-history.js && git add HISTORY.md"
}, },
"version": "0.3.1" "version": "0.4.0"
} }

1
node_modules/debug/.coveralls.yml generated vendored

@ -1 +0,0 @@
repo_token: SIAeZjKYlHK74rbcFvNHMUzjRiMpflxve

11
node_modules/debug/.eslintrc generated vendored

@ -1,11 +0,0 @@
{
"env": {
"browser": true,
"node": true
},
"rules": {
"no-console": 0,
"no-empty": [1, { "allowEmptyCatch": true }]
},
"extends": "eslint:recommended"
}

9
node_modules/debug/.npmignore generated vendored

@ -1,9 +0,0 @@
support
test
examples
example
*.sock
dist
yarn.lock
coverage
bower.json

14
node_modules/debug/.travis.yml generated vendored

@ -1,14 +0,0 @@
language: node_js
node_js:
- "6"
- "5"
- "4"
install:
- make node_modules
script:
- make lint
- make test
- make coveralls

35
node_modules/debug/CHANGELOG.md generated vendored

@ -1,4 +1,37 @@
3.1.0 / 2017-09-26
==================
* Add `DEBUG_HIDE_DATE` env var (#486)
* Remove ReDoS regexp in %o formatter (#504)
* Remove "component" from package.json
* Remove `component.json`
* Ignore package-lock.json
* Examples: fix colors printout
* Fix: browser detection
* Fix: spelling mistake (#496, @EdwardBetts)
3.0.1 / 2017-08-24
==================
* Fix: Disable colors in Edge and Internet Explorer (#489)
3.0.0 / 2017-08-08
==================
* Breaking: Remove DEBUG_FD (#406)
* Breaking: Use `Date#toISOString()` instead to `Date#toUTCString()` when output is not a TTY (#418)
* Breaking: Make millisecond timer namespace specific and allow 'always enabled' output (#408)
* Addition: document `enabled` flag (#465)
* Addition: add 256 colors mode (#481)
* Addition: `enabled()` updates existing debug instances, add `destroy()` function (#440)
* Update: component: update "ms" to v2.0.0
* Update: separate the Node and Browser tests in Travis-CI
* Update: refactor Readme, fixed documentation, added "Namespace Colors" section, redid screenshots
* Update: separate Node.js and web browser examples for organization
* Update: update "browserify" to v14.4.0
* Fix: fix Readme typo (#473)
2.6.9 / 2017-09-22 2.6.9 / 2017-09-22
================== ==================
@ -27,7 +60,7 @@
2.6.4 / 2017-04-20 2.6.4 / 2017-04-20
================== ==================
* Fix: bug that would occure if process.env.DEBUG is a non-string value. (#444, @LucianBuzzo) * Fix: bug that would occur if process.env.DEBUG is a non-string value. (#444, @LucianBuzzo)
* Chore: ignore bower.json in npm installations. (#437, @joaovieira) * Chore: ignore bower.json in npm installations. (#437, @joaovieira)
* Misc: update "ms" to v0.7.3 (@tootallnate) * Misc: update "ms" to v0.7.3 (@tootallnate)

50
node_modules/debug/Makefile generated vendored

@ -1,50 +0,0 @@
# get Makefile directory name: http://stackoverflow.com/a/5982798/376773
THIS_MAKEFILE_PATH:=$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))
THIS_DIR:=$(shell cd $(dir $(THIS_MAKEFILE_PATH));pwd)
# BIN directory
BIN := $(THIS_DIR)/node_modules/.bin
# Path
PATH := node_modules/.bin:$(PATH)
SHELL := /bin/bash
# applications
NODE ?= $(shell which node)
YARN ?= $(shell which yarn)
PKG ?= $(if $(YARN),$(YARN),$(NODE) $(shell which npm))
BROWSERIFY ?= $(NODE) $(BIN)/browserify
.FORCE:
install: node_modules
node_modules: package.json
@NODE_ENV= $(PKG) install
@touch node_modules
lint: .FORCE
eslint browser.js debug.js index.js node.js
test-node: .FORCE
istanbul cover node_modules/mocha/bin/_mocha -- test/**.js
test-browser: .FORCE
mkdir -p dist
@$(BROWSERIFY) \
--standalone debug \
. > dist/debug.js
karma start --single-run
rimraf dist
test: .FORCE
concurrently \
"make test-node" \
"make test-browser"
coveralls:
cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js
.PHONY: all install clean distclean

269
node_modules/debug/README.md generated vendored

@ -1,12 +1,11 @@
# debug # debug
[![Build Status](https://travis-ci.org/visionmedia/debug.svg?branch=master)](https://travis-ci.org/visionmedia/debug) [![Coverage Status](https://coveralls.io/repos/github/visionmedia/debug/badge.svg?branch=master)](https://coveralls.io/github/visionmedia/debug?branch=master) [![Slack](https://visionmedia-community-slackin.now.sh/badge.svg)](https://visionmedia-community-slackin.now.sh/) [![OpenCollective](https://opencollective.com/debug/backers/badge.svg)](#backers) [![Build Status](https://travis-ci.org/visionmedia/debug.svg?branch=master)](https://travis-ci.org/visionmedia/debug) [![Coverage Status](https://coveralls.io/repos/github/visionmedia/debug/badge.svg?branch=master)](https://coveralls.io/github/visionmedia/debug?branch=master) [![Slack](https://visionmedia-community-slackin.now.sh/badge.svg)](https://visionmedia-community-slackin.now.sh/) [![OpenCollective](https://opencollective.com/debug/backers/badge.svg)](#backers)
[![OpenCollective](https://opencollective.com/debug/sponsors/badge.svg)](#sponsors) [![OpenCollective](https://opencollective.com/debug/sponsors/badge.svg)](#sponsors)
<img width="647" src="https://user-images.githubusercontent.com/71256/29091486-fa38524c-7c37-11e7-895f-e7ec8e1039b6.png">
A tiny JavaScript debugging utility modelled after Node.js core's debugging
A tiny node.js debugging utility modelled after node core's debugging technique. technique. Works in Node.js and web browsers.
**Discussion around the V3 API is under way [here](https://github.com/visionmedia/debug/issues/370)**
## Installation ## Installation
@ -18,7 +17,7 @@ $ npm install debug
`debug` exposes a function; simply pass this function the name of your module, and it will return a decorated version of `console.error` for you to pass debug statements to. This will allow you to toggle the debug output for different parts of your module as well as the module as a whole. `debug` exposes a function; simply pass this function the name of your module, and it will return a decorated version of `console.error` for you to pass debug statements to. This will allow you to toggle the debug output for different parts of your module as well as the module as a whole.
Example _app.js_: Example [_app.js_](./examples/node/app.js):
```js ```js
var debug = require('debug')('http') var debug = require('debug')('http')
@ -27,7 +26,7 @@ var debug = require('debug')('http')
// fake app // fake app
debug('booting %s', name); debug('booting %o', name);
http.createServer(function(req, res){ http.createServer(function(req, res){
debug(req.method + ' ' + req.url); debug(req.method + ' ' + req.url);
@ -41,81 +40,148 @@ http.createServer(function(req, res){
require('./worker'); require('./worker');
``` ```
Example _worker.js_: Example [_worker.js_](./examples/node/worker.js):
```js ```js
var debug = require('debug')('worker'); var a = require('debug')('worker:a')
, b = require('debug')('worker:b');
setInterval(function(){ function work() {
debug('doing some work'); a('doing lots of uninteresting work');
}, 1000); setTimeout(work, Math.random() * 1000);
}
work();
function workb() {
b('doing some work');
setTimeout(workb, Math.random() * 2000);
}
workb();
``` ```
The __DEBUG__ environment variable is then used to enable these based on space or comma-delimited names. Here are some examples: The `DEBUG` environment variable is then used to enable these based on space or
comma-delimited names.
![debug http and worker](http://f.cl.ly/items/18471z1H402O24072r1J/Screenshot.png) Here are some examples:
![debug worker](http://f.cl.ly/items/1X413v1a3M0d3C2c1E0i/Screenshot.png) <img width="647" alt="screen shot 2017-08-08 at 12 53 04 pm" src="https://user-images.githubusercontent.com/71256/29091703-a6302cdc-7c38-11e7-8304-7c0b3bc600cd.png">
<img width="647" alt="screen shot 2017-08-08 at 12 53 38 pm" src="https://user-images.githubusercontent.com/71256/29091700-a62a6888-7c38-11e7-800b-db911291ca2b.png">
<img width="647" alt="screen shot 2017-08-08 at 12 53 25 pm" src="https://user-images.githubusercontent.com/71256/29091701-a62ea114-7c38-11e7-826a-2692bedca740.png">
#### Windows note #### Windows command prompt notes
On Windows the environment variable is set using the `set` command. ##### CMD
```cmd On Windows the environment variable is set using the `set` command.
set DEBUG=*,-not_this
```
Note that PowerShell uses different syntax to set environment variables. ```cmd
set DEBUG=*,-not_this
```
Example:
```cmd
set DEBUG=* & node app.js
```
##### PowerShell (VS Code default)
```cmd PowerShell uses different syntax to set environment variables.
$env:DEBUG = "*,-not_this"
``` ```cmd
$env:DEBUG = "*,-not_this"
```
Example:
```cmd
$env:DEBUG='app';node app.js
```
Then, run the program to be debugged as usual. Then, run the program to be debugged as usual.
npm script example:
```js
"windowsDebug": "@powershell -Command $env:DEBUG='*';node app.js",
```
## Namespace Colors
Every debug instance has a color generated for it based on its namespace name.
This helps when visually parsing the debug output to identify which debug instance
a debug line belongs to.
#### Node.js
In Node.js, colors are enabled when stderr is a TTY. You also _should_ install
the [`supports-color`](https://npmjs.org/supports-color) module alongside debug,
otherwise debug will only use a small handful of basic colors.
<img width="521" src="https://user-images.githubusercontent.com/71256/29092181-47f6a9e6-7c3a-11e7-9a14-1928d8a711cd.png">
#### Web Browser
Colors are also enabled on "Web Inspectors" that understand the `%c` formatting
option. These are WebKit web inspectors, Firefox ([since version
31](https://hacks.mozilla.org/2014/05/editable-box-model-multiple-selection-sublime-text-keys-much-more-firefox-developer-tools-episode-31/))
and the Firebug plugin for Firefox (any version).
<img width="524" src="https://user-images.githubusercontent.com/71256/29092033-b65f9f2e-7c39-11e7-8e32-f6f0d8e865c1.png">
## Millisecond diff ## Millisecond diff
When actively developing an application it can be useful to see when the time spent between one `debug()` call and the next. Suppose for example you invoke `debug()` before requesting a resource, and after as well, the "+NNNms" will show you how much time was spent between calls. When actively developing an application it can be useful to see when the time spent between one `debug()` call and the next. Suppose for example you invoke `debug()` before requesting a resource, and after as well, the "+NNNms" will show you how much time was spent between calls.
<img width="647" src="https://user-images.githubusercontent.com/71256/29091486-fa38524c-7c37-11e7-895f-e7ec8e1039b6.png">
![](http://f.cl.ly/items/2i3h1d3t121M2Z1A3Q0N/Screenshot.png) When stdout is not a TTY, `Date#toISOString()` is used, making it more useful for logging the debug information as shown below:
When stdout is not a TTY, `Date#toUTCString()` is used, making it more useful for logging the debug information as shown below: <img width="647" src="https://user-images.githubusercontent.com/71256/29091956-6bd78372-7c39-11e7-8c55-c948396d6edd.png">
![](http://f.cl.ly/items/112H3i0e0o0P0a2Q2r11/Screenshot.png)
## Conventions ## Conventions
If you're using this in one or more of your libraries, you _should_ use the name of your library so that developers may toggle debugging as desired without guessing names. If you have more than one debuggers you _should_ prefix them with your library name and use ":" to separate features. For example "bodyParser" from Connect would then be "connect:bodyParser". If you're using this in one or more of your libraries, you _should_ use the name of your library so that developers may toggle debugging as desired without guessing names. If you have more than one debuggers you _should_ prefix them with your library name and use ":" to separate features. For example "bodyParser" from Connect would then be "connect:bodyParser". If you append a "*" to the end of your name, it will always be enabled regardless of the setting of the DEBUG environment variable. You can then use it for normal output as well as debug output.
## Wildcards ## Wildcards
The `*` character may be used as a wildcard. Suppose for example your library has debuggers named "connect:bodyParser", "connect:compress", "connect:session", instead of listing all three with `DEBUG=connect:bodyParser,connect:compress,connect:session`, you may simply do `DEBUG=connect:*`, or to run everything using this module simply use `DEBUG=*`. The `*` character may be used as a wildcard. Suppose for example your library has
debuggers named "connect:bodyParser", "connect:compress", "connect:session",
instead of listing all three with
`DEBUG=connect:bodyParser,connect:compress,connect:session`, you may simply do
`DEBUG=connect:*`, or to run everything using this module simply use `DEBUG=*`.
You can also exclude specific debuggers by prefixing them with a "-" character. For example, `DEBUG=*,-connect:*` would include all debuggers except those starting with "connect:". You can also exclude specific debuggers by prefixing them with a "-" character.
For example, `DEBUG=*,-connect:*` would include all debuggers except those
starting with "connect:".
## Environment Variables ## Environment Variables
When running through Node.js, you can set a few environment variables that will When running through Node.js, you can set a few environment variables that will
change the behavior of the debug logging: change the behavior of the debug logging:
| Name | Purpose | | Name | Purpose |
|-----------|-------------------------------------------------| |-----------|-------------------------------------------------|
| `DEBUG` | Enables/disables specific debugging namespaces. | | `DEBUG` | Enables/disables specific debugging namespaces. |
| `DEBUG_HIDE_DATE` | Hide date from debug output (non-TTY). |
| `DEBUG_COLORS`| Whether or not to use colors in the debug output. | | `DEBUG_COLORS`| Whether or not to use colors in the debug output. |
| `DEBUG_DEPTH` | Object inspection depth. | | `DEBUG_DEPTH` | Object inspection depth. |
| `DEBUG_SHOW_HIDDEN` | Shows hidden properties on inspected objects. | | `DEBUG_SHOW_HIDDEN` | Shows hidden properties on inspected objects. |
__Note:__ The environment variables beginning with `DEBUG_` end up being __Note:__ The environment variables beginning with `DEBUG_` end up being
converted into an Options object that gets used with `%o`/`%O` formatters. converted into an Options object that gets used with `%o`/`%O` formatters.
See the Node.js documentation for See the Node.js documentation for
[`util.inspect()`](https://nodejs.org/api/util.html#util_util_inspect_object_options) [`util.inspect()`](https://nodejs.org/api/util.html#util_util_inspect_object_options)
for the complete list. for the complete list.
## Formatters ## Formatters
Debug uses [printf-style](https://wikipedia.org/wiki/Printf_format_string) formatting.
Debug uses [printf-style](https://wikipedia.org/wiki/Printf_format_string) formatting. Below are the officially supported formatters: Below are the officially supported formatters:
| Formatter | Representation | | Formatter | Representation |
|-----------|----------------| |-----------|----------------|
@ -126,9 +192,12 @@ Then, run the program to be debugged as usual.
| `%j` | JSON. Replaced with the string '[Circular]' if the argument contains circular references. | | `%j` | JSON. Replaced with the string '[Circular]' if the argument contains circular references. |
| `%%` | Single percent sign ('%'). This does not consume an argument. | | `%%` | Single percent sign ('%'). This does not consume an argument. |
### Custom formatters ### Custom formatters
You can add custom formatters by extending the `debug.formatters` object. For example, if you wanted to add support for rendering a Buffer as hex with `%h`, you could do something like: You can add custom formatters by extending the `debug.formatters` object.
For example, if you wanted to add support for rendering a Buffer as hex with
`%h`, you could do something like:
```js ```js
const createDebug = require('debug') const createDebug = require('debug')
@ -142,14 +211,16 @@ debug('this is hex: %h', new Buffer('hello world'))
// foo this is hex: 68656c6c6f20776f726c6421 +0ms // foo this is hex: 68656c6c6f20776f726c6421 +0ms
``` ```
## Browser support
You can build a browser-ready script using [browserify](https://github.com/substack/node-browserify),
or just use the [browserify-as-a-service](https://wzrd.in/) [build](https://wzrd.in/standalone/debug@latest),
if you don't want to build it yourself.
Debug's enable state is currently persisted by `localStorage`. ## Browser Support
Consider the situation shown below where you have `worker:a` and `worker:b`,
and wish to debug both. You can enable this using `localStorage.debug`: You can build a browser-ready script using [browserify](https://github.com/substack/node-browserify),
or just use the [browserify-as-a-service](https://wzrd.in/) [build](https://wzrd.in/standalone/debug@latest),
if you don't want to build it yourself.
Debug's enable state is currently persisted by `localStorage`.
Consider the situation shown below where you have `worker:a` and `worker:b`,
and wish to debug both. You can enable this using `localStorage.debug`:
```js ```js
localStorage.debug = 'worker:*' localStorage.debug = 'worker:*'
@ -170,23 +241,12 @@ setInterval(function(){
}, 1200); }, 1200);
``` ```
#### Web Inspector Colors
Colors are also enabled on "Web Inspectors" that understand the `%c` formatting
option. These are WebKit web inspectors, Firefox ([since version
31](https://hacks.mozilla.org/2014/05/editable-box-model-multiple-selection-sublime-text-keys-much-more-firefox-developer-tools-episode-31/))
and the Firebug plugin for Firefox (any version).
Colored output looks something like:
![](https://cloud.githubusercontent.com/assets/71256/3139768/b98c5fd8-e8ef-11e3-862a-f7253b6f47c6.png)
## Output streams ## Output streams
By default `debug` will log to stderr, however this can be configured per-namespace by overriding the `log` method: By default `debug` will log to stderr, however this can be configured per-namespace by overriding the `log` method:
Example _stdout.js_: Example [_stdout.js_](./examples/node/stdout.js):
```js ```js
var debug = require('debug'); var debug = require('debug');
@ -208,13 +268,96 @@ error('now goes to stdout via console.info');
log('still goes to stdout, but via console.info now'); log('still goes to stdout, but via console.info now');
``` ```
## Extend
You can simply extend debugger
```js
const log = require('debug')('auth');
//creates new debug instance with extended namespace
const logSign = log.extend('sign');
const logLogin = log.extend('login');
log('hello'); // auth hello
logSign('hello'); //auth:sign hello
logLogin('hello'); //auth:login hello
```
## Set dynamically
You can also enable debug dynamically by calling the `enable()` method :
```js
let debug = require('debug');
console.log(1, debug.enabled('test'));
debug.enable('test');
console.log(2, debug.enabled('test'));
debug.disable();
console.log(3, debug.enabled('test'));
```
print :
```
1 false
2 true
3 false
```
Usage :
`enable(namespaces)`
`namespaces` can include modes separated by a colon and wildcards.
Note that calling `enable()` completely overrides previously set DEBUG variable :
```
$ DEBUG=foo node -e 'var dbg = require("debug"); dbg.enable("bar"); console.log(dbg.enabled("foo"))'
=> false
```
`disable()`
Will disable all namespaces. The functions returns the namespaces currently
enabled (and skipped). This can be useful if you want to disable debugging
temporarily without knowing what was enabled to begin with.
For example:
```js
let debug = require('debug');
debug.enable('foo:*,-foo:bar');
let namespaces = debug.disable();
debug.enable(namespaces);
```
Note: There is no guarantee that the string will be identical to the initial
enable string, but semantically they will be identical.
## Checking whether a debug target is enabled
After you've created a debug instance, you can determine whether or not it is
enabled by checking the `enabled` property:
```javascript
const debug = require('debug')('http');
if (debug.enabled) {
// do stuff...
}
```
You can also manually toggle this property to force the debug instance to be
enabled or disabled.
## Authors ## Authors
- TJ Holowaychuk - TJ Holowaychuk
- Nathan Rajlich - Nathan Rajlich
- Andrew Rhyne - Andrew Rhyne
## Backers ## Backers
Support us with a monthly donation and help us continue our activities. [[Become a backer](https://opencollective.com/debug#backer)] Support us with a monthly donation and help us continue our activities. [[Become a backer](https://opencollective.com/debug#backer)]
@ -290,7 +433,7 @@ Become a sponsor and get your logo on our README on Github with a link to your s
(The MIT License) (The MIT License)
Copyright (c) 2014-2016 TJ Holowaychuk &lt;tj@vision-media.ca&gt; Copyright (c) 2014-2017 TJ Holowaychuk &lt;tj@vision-media.ca&gt;
Permission is hereby granted, free of charge, to any person obtaining Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the a copy of this software and associated documentation files (the

19
node_modules/debug/component.json generated vendored

@ -1,19 +0,0 @@
{
"name": "debug",
"repo": "visionmedia/debug",
"description": "small debugging utility",
"version": "2.6.9",
"keywords": [
"debug",
"log",
"debugger"
],
"main": "src/browser.js",
"scripts": [
"src/browser.js",
"src/debug.js"
],
"dependencies": {
"rauchg/ms.js": "0.7.1"
}
}

70
node_modules/debug/karma.conf.js generated vendored

@ -1,70 +0,0 @@
// Karma configuration
// Generated on Fri Dec 16 2016 13:09:51 GMT+0000 (UTC)
module.exports = function(config) {
config.set({
// base path that will be used to resolve all patterns (eg. files, exclude)
basePath: '',
// frameworks to use
// available frameworks: https://npmjs.org/browse/keyword/karma-adapter
frameworks: ['mocha', 'chai', 'sinon'],
// list of files / patterns to load in the browser
files: [
'dist/debug.js',
'test/*spec.js'
],
// list of files to exclude
exclude: [
'src/node.js'
],
// preprocess matching files before serving them to the browser
// available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
preprocessors: {
},
// test results reporter to use
// possible values: 'dots', 'progress'
// available reporters: https://npmjs.org/browse/keyword/karma-reporter
reporters: ['progress'],
// web server port
port: 9876,
// enable / disable colors in the output (reporters and logs)
colors: true,
// level of logging
// possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
logLevel: config.LOG_INFO,
// enable / disable watching file and executing tests whenever any file changes
autoWatch: true,
// start these browsers
// available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
browsers: ['PhantomJS'],
// Continuous Integration mode
// if true, Karma captures browsers, runs the tests and exits
singleRun: false,
// Concurrency level
// how many browser should be started simultaneous
concurrency: Infinity
})
}

1
node_modules/debug/node.js generated vendored

@ -1 +0,0 @@
module.exports = require('./src/node');

73
node_modules/debug/package.json generated vendored

@ -1,32 +1,29 @@
{ {
"_from": "debug@~2.6.9", "_from": "debug@^4.1.1",
"_id": "debug@2.6.9", "_id": "debug@4.1.1",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "_integrity": "sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw==",
"_location": "/debug", "_location": "/debug",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "debug@~2.6.9", "raw": "debug@^4.1.1",
"name": "debug", "name": "debug",
"escapedName": "debug", "escapedName": "debug",
"rawSpec": "~2.6.9", "rawSpec": "^4.1.1",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~2.6.9" "fetchSpec": "^4.1.1"
}, },
"_requiredBy": [ "_requiredBy": [
"/", "/",
"/body-parser", "/@babel/core",
"/express", "/@babel/traverse"
"/finalhandler",
"/morgan",
"/send"
], ],
"_resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", "_resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz",
"_shasum": "5d128515df134ff327e90a4c93f4e077a536341f", "_shasum": "3b72260255109c6b589cee050f1d516139664791",
"_spec": "debug@~2.6.9", "_spec": "debug@^4.1.1",
"_where": "/home/f2256342/forge/es6-nodejs", "_where": "/home/yutsuo/forge/nodejs/es6-express",
"author": { "author": {
"name": "TJ Holowaychuk", "name": "TJ Holowaychuk",
"email": "tj@vision-media.ca" "email": "tj@vision-media.ca"
@ -36,12 +33,6 @@
"url": "https://github.com/visionmedia/debug/issues" "url": "https://github.com/visionmedia/debug/issues"
}, },
"bundleDependencies": false, "bundleDependencies": false,
"component": {
"scripts": {
"debug/index.js": "browser.js",
"debug/debug.js": "debug.js"
}
},
"contributors": [ "contributors": [
{ {
"name": "Nathan Rajlich", "name": "Nathan Rajlich",
@ -54,28 +45,34 @@
} }
], ],
"dependencies": { "dependencies": {
"ms": "2.0.0" "ms": "^2.1.1"
}, },
"deprecated": false, "deprecated": false,
"description": "small debugging utility", "description": "small debugging utility",
"devDependencies": { "devDependencies": {
"browserify": "9.0.3", "@babel/cli": "^7.0.0",
"@babel/core": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"browserify": "14.4.0",
"chai": "^3.5.0", "chai": "^3.5.0",
"concurrently": "^3.1.0", "concurrently": "^3.1.0",
"coveralls": "^2.11.15", "coveralls": "^3.0.2",
"eslint": "^3.12.1",
"istanbul": "^0.4.5", "istanbul": "^0.4.5",
"karma": "^1.3.0", "karma": "^3.0.0",
"karma-chai": "^0.1.0", "karma-chai": "^0.1.0",
"karma-mocha": "^1.3.0", "karma-mocha": "^1.3.0",
"karma-phantomjs-launcher": "^1.0.2", "karma-phantomjs-launcher": "^1.0.2",
"karma-sinon": "^1.0.5", "mocha": "^5.2.0",
"mocha": "^3.2.0",
"mocha-lcov-reporter": "^1.2.0", "mocha-lcov-reporter": "^1.2.0",
"rimraf": "^2.5.4", "rimraf": "^2.5.4",
"sinon": "^1.17.6", "xo": "^0.23.0"
"sinon-chai": "^2.8.0"
}, },
"files": [
"src",
"dist/debug.js",
"LICENSE",
"README.md"
],
"homepage": "https://github.com/visionmedia/debug#readme", "homepage": "https://github.com/visionmedia/debug#readme",
"keywords": [ "keywords": [
"debug", "debug",
@ -89,5 +86,19 @@
"type": "git", "type": "git",
"url": "git://github.com/visionmedia/debug.git" "url": "git://github.com/visionmedia/debug.git"
}, },
"version": "2.6.9" "scripts": {
"build": "npm run build:debug && npm run build:test",
"build:debug": "babel -o dist/debug.js dist/debug.es6.js > dist/debug.js",
"build:test": "babel -d dist test.js",
"clean": "rimraf dist coverage",
"lint": "xo",
"prebuild:debug": "mkdir -p dist && browserify --standalone debug -o dist/debug.es6.js .",
"pretest:browser": "npm run build",
"test": "npm run test:node && npm run test:browser",
"test:browser": "karma start --single-run",
"test:coverage": "cat ./coverage/lcov.info | coveralls",
"test:node": "istanbul cover _mocha -- test.js"
},
"unpkg": "./dist/debug.js",
"version": "4.1.1"
} }

291
node_modules/debug/src/browser.js generated vendored

@ -1,31 +1,97 @@
/* eslint-env browser */
/** /**
* This is the web browser implementation of `debug()`. * This is the web browser implementation of `debug()`.
*
* Expose `debug()` as the module.
*/ */
exports = module.exports = require('./debug');
exports.log = log; exports.log = log;
exports.formatArgs = formatArgs; exports.formatArgs = formatArgs;
exports.save = save; exports.save = save;
exports.load = load; exports.load = load;
exports.useColors = useColors; exports.useColors = useColors;
exports.storage = 'undefined' != typeof chrome exports.storage = localstorage();
&& 'undefined' != typeof chrome.storage
? chrome.storage.local
: localstorage();
/** /**
* Colors. * Colors.
*/ */
exports.colors = [ exports.colors = [
'lightseagreen', '#0000CC',
'forestgreen', '#0000FF',
'goldenrod', '#0033CC',
'dodgerblue', '#0033FF',
'darkorchid', '#0066CC',
'crimson' '#0066FF',
'#0099CC',
'#0099FF',
'#00CC00',
'#00CC33',
'#00CC66',
'#00CC99',
'#00CCCC',
'#00CCFF',
'#3300CC',
'#3300FF',
'#3333CC',
'#3333FF',
'#3366CC',
'#3366FF',
'#3399CC',
'#3399FF',
'#33CC00',
'#33CC33',
'#33CC66',
'#33CC99',
'#33CCCC',
'#33CCFF',
'#6600CC',
'#6600FF',
'#6633CC',
'#6633FF',
'#66CC00',
'#66CC33',
'#9900CC',
'#9900FF',
'#9933CC',
'#9933FF',
'#99CC00',
'#99CC33',
'#CC0000',
'#CC0033',
'#CC0066',
'#CC0099',
'#CC00CC',
'#CC00FF',
'#CC3300',
'#CC3333',
'#CC3366',
'#CC3399',
'#CC33CC',
'#CC33FF',
'#CC6600',
'#CC6633',
'#CC9900',
'#CC9933',
'#CCCC00',
'#CCCC33',
'#FF0000',
'#FF0033',
'#FF0066',
'#FF0099',
'#FF00CC',
'#FF00FF',
'#FF3300',
'#FF3333',
'#FF3366',
'#FF3399',
'#FF33CC',
'#FF33FF',
'#FF6600',
'#FF6633',
'#FF9900',
'#FF9933',
'#FFCC00',
'#FFCC33'
]; ];
/** /**
@ -36,38 +102,31 @@ exports.colors = [
* TODO: add a `localStorage` variable to explicitly enable/disable colors * TODO: add a `localStorage` variable to explicitly enable/disable colors
*/ */
// eslint-disable-next-line complexity
function useColors() { function useColors() {
// NB: In an Electron preload script, document will be defined but not fully // NB: In an Electron preload script, document will be defined but not fully
// initialized. Since we know we're in Chrome, we'll just detect this case // initialized. Since we know we're in Chrome, we'll just detect this case
// explicitly // explicitly
if (typeof window !== 'undefined' && window.process && window.process.type === 'renderer') { if (typeof window !== 'undefined' && window.process && (window.process.type === 'renderer' || window.process.__nwjs)) {
return true; return true;
} }
// is webkit? http://stackoverflow.com/a/16459606/376773
// document is undefined in react-native: https://github.com/facebook/react-native/pull/1632
return (typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance) ||
// is firebug? http://stackoverflow.com/a/398120/376773
(typeof window !== 'undefined' && window.console && (window.console.firebug || (window.console.exception && window.console.table))) ||
// is firefox >= v31?
// https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages
(typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31) ||
// double check webkit in userAgent just in case we are in a worker
(typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/));
}
/**
* Map %j to `JSON.stringify()`, since no Web Inspectors do that by default.
*/
exports.formatters.j = function(v) { // Internet Explorer and Edge do not support colors.
try { if (typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) {
return JSON.stringify(v); return false;
} catch (err) { }
return '[UnexpectedJSONParseError]: ' + err.message;
}
};
// Is webkit? http://stackoverflow.com/a/16459606/376773
// document is undefined in react-native: https://github.com/facebook/react-native/pull/1632
return (typeof document !== 'undefined' && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance) ||
// Is firebug? http://stackoverflow.com/a/398120/376773
(typeof window !== 'undefined' && window.console && (window.console.firebug || (window.console.exception && window.console.table))) ||
// Is firefox >= v31?
// https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages
(typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31) ||
// Double check webkit in userAgent just in case we are in a worker
(typeof navigator !== 'undefined' && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/));
}
/** /**
* Colorize log arguments if enabled. * Colorize log arguments if enabled.
@ -76,36 +135,38 @@ exports.formatters.j = function(v) {
*/ */
function formatArgs(args) { function formatArgs(args) {
var useColors = this.useColors; args[0] = (this.useColors ? '%c' : '') +
this.namespace +
args[0] = (useColors ? '%c' : '') (this.useColors ? ' %c' : ' ') +
+ this.namespace args[0] +
+ (useColors ? ' %c' : ' ') (this.useColors ? '%c ' : ' ') +
+ args[0] '+' + module.exports.humanize(this.diff);
+ (useColors ? '%c ' : ' ')
+ '+' + exports.humanize(this.diff); if (!this.useColors) {
return;
if (!useColors) return; }
var c = 'color: ' + this.color; const c = 'color: ' + this.color;
args.splice(1, 0, c, 'color: inherit') args.splice(1, 0, c, 'color: inherit');
// the final "%c" is somewhat tricky, because there could be other // The final "%c" is somewhat tricky, because there could be other
// arguments passed either before or after the %c, so we need to // arguments passed either before or after the %c, so we need to
// figure out the correct index to insert the CSS into // figure out the correct index to insert the CSS into
var index = 0; let index = 0;
var lastC = 0; let lastC = 0;
args[0].replace(/%[a-zA-Z%]/g, function(match) { args[0].replace(/%[a-zA-Z%]/g, match => {
if ('%%' === match) return; if (match === '%%') {
index++; return;
if ('%c' === match) { }
// we only are interested in the *last* %c index++;
// (the user may have provided their own) if (match === '%c') {
lastC = index; // We only are interested in the *last* %c
} // (the user may have provided their own)
}); lastC = index;
}
args.splice(lastC, 0, c); });
args.splice(lastC, 0, c);
} }
/** /**
@ -114,13 +175,12 @@ function formatArgs(args) {
* *
* @api public * @api public
*/ */
function log(...args) {
function log() { // This hackery is required for IE8/9, where
// this hackery is required for IE8/9, where // the `console.log` function doesn't have 'apply'
// the `console.log` function doesn't have 'apply' return typeof console === 'object' &&
return 'object' === typeof console console.log &&
&& console.log console.log(...args);
&& Function.prototype.apply.call(console.log, console, arguments);
} }
/** /**
@ -129,15 +189,17 @@ function log() {
* @param {String} namespaces * @param {String} namespaces
* @api private * @api private
*/ */
function save(namespaces) { function save(namespaces) {
try { try {
if (null == namespaces) { if (namespaces) {
exports.storage.removeItem('debug'); exports.storage.setItem('debug', namespaces);
} else { } else {
exports.storage.debug = namespaces; exports.storage.removeItem('debug');
} }
} catch(e) {} } catch (error) {
// Swallow
// XXX (@Qix-) should we be logging these?
}
} }
/** /**
@ -146,27 +208,23 @@ function save(namespaces) {
* @return {String} returns the previously persisted debug modes * @return {String} returns the previously persisted debug modes
* @api private * @api private
*/ */
function load() { function load() {
var r; let r;
try { try {
r = exports.storage.debug; r = exports.storage.getItem('debug');
} catch(e) {} } catch (error) {
// Swallow
// XXX (@Qix-) should we be logging these?
}
// If debug isn't set in LS, and we're in Electron, try to load $DEBUG // If debug isn't set in LS, and we're in Electron, try to load $DEBUG
if (!r && typeof process !== 'undefined' && 'env' in process) { if (!r && typeof process !== 'undefined' && 'env' in process) {
r = process.env.DEBUG; r = process.env.DEBUG;
} }
return r; return r;
} }
/**
* Enable namespaces listed in `localStorage.debug` initially.
*/
exports.enable(load());
/** /**
* Localstorage attempts to return the localstorage. * Localstorage attempts to return the localstorage.
* *
@ -179,7 +237,28 @@ exports.enable(load());
*/ */
function localstorage() { function localstorage() {
try { try {
return window.localStorage; // TVMLKit (Apple TV JS Runtime) does not have a window object, just localStorage in the global context
} catch (e) {} // The Browser also has localStorage in the global context.
return localStorage;
} catch (error) {
// Swallow
// XXX (@Qix-) should we be logging these?
}
} }
module.exports = require('./common')(exports);
const {formatters} = module.exports;
/**
* Map %j to `JSON.stringify()`, since no Web Inspectors do that by default.
*/
formatters.j = function (v) {
try {
return JSON.stringify(v);
} catch (error) {
return '[UnexpectedJSONParseError]: ' + error.message;
}
};

202
node_modules/debug/src/debug.js generated vendored

@ -1,202 +0,0 @@
/**
* This is the common logic for both the Node.js and web browser
* implementations of `debug()`.
*
* Expose `debug()` as the module.
*/
exports = module.exports = createDebug.debug = createDebug['default'] = createDebug;
exports.coerce = coerce;
exports.disable = disable;
exports.enable = enable;
exports.enabled = enabled;
exports.humanize = require('ms');
/**
* The currently active debug mode names, and names to skip.
*/
exports.names = [];
exports.skips = [];
/**
* Map of special "%n" handling functions, for the debug "format" argument.
*
* Valid key names are a single, lower or upper-case letter, i.e. "n" and "N".
*/
exports.formatters = {};
/**
* Previous log timestamp.
*/
var prevTime;
/**
* Select a color.
* @param {String} namespace
* @return {Number}
* @api private
*/
function selectColor(namespace) {
var hash = 0, i;
for (i in namespace) {
hash = ((hash << 5) - hash) + namespace.charCodeAt(i);
hash |= 0; // Convert to 32bit integer
}
return exports.colors[Math.abs(hash) % exports.colors.length];
}
/**
* Create a debugger with the given `namespace`.
*
* @param {String} namespace
* @return {Function}
* @api public
*/
function createDebug(namespace) {
function debug() {
// disabled?
if (!debug.enabled) return;
var self = debug;
// set `diff` timestamp
var curr = +new Date();
var ms = curr - (prevTime || curr);
self.diff = ms;
self.prev = prevTime;
self.curr = curr;
prevTime = curr;
// turn the `arguments` into a proper Array
var args = new Array(arguments.length);
for (var i = 0; i < args.length; i++) {
args[i] = arguments[i];
}
args[0] = exports.coerce(args[0]);
if ('string' !== typeof args[0]) {
// anything else let's inspect with %O
args.unshift('%O');
}
// apply any `formatters` transformations
var index = 0;
args[0] = args[0].replace(/%([a-zA-Z%])/g, function(match, format) {
// if we encounter an escaped % then don't increase the array index
if (match === '%%') return match;
index++;
var formatter = exports.formatters[format];
if ('function' === typeof formatter) {
var val = args[index];
match = formatter.call(self, val);
// now we need to remove `args[index]` since it's inlined in the `format`
args.splice(index, 1);
index--;
}
return match;
});
// apply env-specific formatting (colors, etc.)
exports.formatArgs.call(self, args);
var logFn = debug.log || exports.log || console.log.bind(console);
logFn.apply(self, args);
}
debug.namespace = namespace;
debug.enabled = exports.enabled(namespace);
debug.useColors = exports.useColors();
debug.color = selectColor(namespace);
// env-specific initialization logic for debug instances
if ('function' === typeof exports.init) {
exports.init(debug);
}
return debug;
}
/**
* Enables a debug mode by namespaces. This can include modes
* separated by a colon and wildcards.
*
* @param {String} namespaces
* @api public
*/
function enable(namespaces) {
exports.save(namespaces);
exports.names = [];
exports.skips = [];
var split = (typeof namespaces === 'string' ? namespaces : '').split(/[\s,]+/);
var len = split.length;
for (var i = 0; i < len; i++) {
if (!split[i]) continue; // ignore empty strings
namespaces = split[i].replace(/\*/g, '.*?');
if (namespaces[0] === '-') {
exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$'));
} else {
exports.names.push(new RegExp('^' + namespaces + '$'));
}
}
}
/**
* Disable debug output.
*
* @api public
*/
function disable() {
exports.enable('');
}
/**
* Returns true if the given mode name is enabled, false otherwise.
*
* @param {String} name
* @return {Boolean}
* @api public
*/
function enabled(name) {
var i, len;
for (i = 0, len = exports.skips.length; i < len; i++) {
if (exports.skips[i].test(name)) {
return false;
}
}
for (i = 0, len = exports.names.length; i < len; i++) {
if (exports.names[i].test(name)) {
return true;
}
}
return false;
}
/**
* Coerce `val`.
*
* @param {Mixed} val
* @return {Mixed}
* @api private
*/
function coerce(val) {
if (val instanceof Error) return val.stack || val.message;
return val;
}

8
node_modules/debug/src/index.js generated vendored

@ -1,10 +1,10 @@
/** /**
* Detect Electron renderer process, which is node, but we should * Detect Electron renderer / nwjs process, which is node, but we should
* treat as a browser. * treat as a browser.
*/ */
if (typeof process !== 'undefined' && process.type === 'renderer') { if (typeof process === 'undefined' || process.type === 'renderer' || process.browser === true || process.__nwjs) {
module.exports = require('./browser.js'); module.exports = require('./browser.js');
} else { } else {
module.exports = require('./node.js'); module.exports = require('./node.js');
} }

15
node_modules/debug/src/inspector-log.js generated vendored

@ -1,15 +0,0 @@
module.exports = inspectorLog;
// black hole
const nullStream = new (require('stream').Writable)();
nullStream._write = () => {};
/**
* Outputs a `console.log()` to the Node.js Inspector console *only*.
*/
function inspectorLog() {
const stdout = console._stdout;
console._stdout = nullStream;
console.log.apply(console, arguments);
console._stdout = stdout;
}

339
node_modules/debug/src/node.js generated vendored

@ -2,16 +2,13 @@
* Module dependencies. * Module dependencies.
*/ */
var tty = require('tty'); const tty = require('tty');
var util = require('util'); const util = require('util');
/** /**
* This is the Node.js implementation of `debug()`. * This is the Node.js implementation of `debug()`.
*
* Expose `debug()` as the module.
*/ */
exports = module.exports = require('./debug');
exports.init = init; exports.init = init;
exports.log = log; exports.log = log;
exports.formatArgs = formatArgs; exports.formatArgs = formatArgs;
@ -25,80 +22,138 @@ exports.useColors = useColors;
exports.colors = [6, 2, 3, 4, 5, 1]; exports.colors = [6, 2, 3, 4, 5, 1];
try {
// Optional dependency (as in, doesn't need to be installed, NOT like optionalDependencies in package.json)
// eslint-disable-next-line import/no-extraneous-dependencies
const supportsColor = require('supports-color');
if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) {
exports.colors = [
20,
21,
26,
27,
32,
33,
38,
39,
40,
41,
42,
43,
44,
45,
56,
57,
62,
63,
68,
69,
74,
75,
76,
77,
78,
79,
80,
81,
92,
93,
98,
99,
112,
113,
128,
129,
134,
135,
148,
149,
160,
161,
162,
163,
164,
165,
166,
167,
168,
169,
170,
171,
172,
173,
178,
179,
184,
185,
196,
197,
198,
199,
200,
201,
202,
203,
204,
205,
206,
207,
208,
209,
214,
215,
220,
221
];
}
} catch (error) {
// Swallow - we only care if `supports-color` is available; it doesn't have to be.
}
/** /**
* Build up the default `inspectOpts` object from the environment variables. * Build up the default `inspectOpts` object from the environment variables.
* *
* $ DEBUG_COLORS=no DEBUG_DEPTH=10 DEBUG_SHOW_HIDDEN=enabled node script.js * $ DEBUG_COLORS=no DEBUG_DEPTH=10 DEBUG_SHOW_HIDDEN=enabled node script.js
*/ */
exports.inspectOpts = Object.keys(process.env).filter(function (key) { exports.inspectOpts = Object.keys(process.env).filter(key => {
return /^debug_/i.test(key); return /^debug_/i.test(key);
}).reduce(function (obj, key) { }).reduce((obj, key) => {
// camel-case // Camel-case
var prop = key const prop = key
.substring(6) .substring(6)
.toLowerCase() .toLowerCase()
.replace(/_([a-z])/g, function (_, k) { return k.toUpperCase() }); .replace(/_([a-z])/g, (_, k) => {
return k.toUpperCase();
// coerce string value into JS value });
var val = process.env[key];
if (/^(yes|on|true|enabled)$/i.test(val)) val = true; // Coerce string value into JS value
else if (/^(no|off|false|disabled)$/i.test(val)) val = false; let val = process.env[key];
else if (val === 'null') val = null; if (/^(yes|on|true|enabled)$/i.test(val)) {
else val = Number(val); val = true;
} else if (/^(no|off|false|disabled)$/i.test(val)) {
obj[prop] = val; val = false;
return obj; } else if (val === 'null') {
val = null;
} else {
val = Number(val);
}
obj[prop] = val;
return obj;
}, {}); }, {});
/**
* The file descriptor to write the `debug()` calls to.
* Set the `DEBUG_FD` env variable to override with another value. i.e.:
*
* $ DEBUG_FD=3 node script.js 3>debug.log
*/
var fd = parseInt(process.env.DEBUG_FD, 10) || 2;
if (1 !== fd && 2 !== fd) {
util.deprecate(function(){}, 'except for stderr(2) and stdout(1), any other usage of DEBUG_FD is deprecated. Override debug.log if you want to use a different log function (https://git.io/debug_fd)')()
}
var stream = 1 === fd ? process.stdout :
2 === fd ? process.stderr :
createWritableStdioStream(fd);
/** /**
* Is stdout a TTY? Colored output is enabled when `true`. * Is stdout a TTY? Colored output is enabled when `true`.
*/ */
function useColors() { function useColors() {
return 'colors' in exports.inspectOpts return 'colors' in exports.inspectOpts ?
? Boolean(exports.inspectOpts.colors) Boolean(exports.inspectOpts.colors) :
: tty.isatty(fd); tty.isatty(process.stderr.fd);
} }
/**
* Map %o to `util.inspect()`, all on a single line.
*/
exports.formatters.o = function(v) {
this.inspectOpts.colors = this.useColors;
return util.inspect(v, this.inspectOpts)
.split('\n').map(function(str) {
return str.trim()
}).join(' ');
};
/**
* Map %o to `util.inspect()`, allowing multiple lines if needed.
*/
exports.formatters.O = function(v) {
this.inspectOpts.colors = this.useColors;
return util.inspect(v, this.inspectOpts);
};
/** /**
* Adds ANSI color escape codes if enabled. * Adds ANSI color escape codes if enabled.
* *
@ -106,27 +161,33 @@ exports.formatters.O = function(v) {
*/ */
function formatArgs(args) { function formatArgs(args) {
var name = this.namespace; const {namespace: name, useColors} = this;
var useColors = this.useColors;
if (useColors) {
if (useColors) { const c = this.color;
var c = this.color; const colorCode = '\u001B[3' + (c < 8 ? c : '8;5;' + c);
var prefix = ' \u001b[3' + c + ';1m' + name + ' ' + '\u001b[0m'; const prefix = ` ${colorCode};1m${name} \u001B[0m`;
args[0] = prefix + args[0].split('\n').join('\n' + prefix); args[0] = prefix + args[0].split('\n').join('\n' + prefix);
args.push('\u001b[3' + c + 'm+' + exports.humanize(this.diff) + '\u001b[0m'); args.push(colorCode + 'm+' + module.exports.humanize(this.diff) + '\u001B[0m');
} else { } else {
args[0] = new Date().toUTCString() args[0] = getDate() + name + ' ' + args[0];
+ ' ' + name + ' ' + args[0]; }
} }
function getDate() {
if (exports.inspectOpts.hideDate) {
return '';
}
return new Date().toISOString() + ' ';
} }
/** /**
* Invokes `util.format()` with the specified arguments and writes to `stream`. * Invokes `util.format()` with the specified arguments and writes to stderr.
*/ */
function log() { function log(...args) {
return stream.write(util.format.apply(util, arguments) + '\n'); return process.stderr.write(util.format(...args) + '\n');
} }
/** /**
@ -135,15 +196,14 @@ function log() {
* @param {String} namespaces * @param {String} namespaces
* @api private * @api private
*/ */
function save(namespaces) { function save(namespaces) {
if (null == namespaces) { if (namespaces) {
// If you set a process.env field to null or undefined, it gets cast to the process.env.DEBUG = namespaces;
// string 'null' or 'undefined'. Just delete instead. } else {
delete process.env.DEBUG; // If you set a process.env field to null or undefined, it gets cast to the
} else { // string 'null' or 'undefined'. Just delete instead.
process.env.DEBUG = namespaces; delete process.env.DEBUG;
} }
} }
/** /**
@ -154,75 +214,7 @@ function save(namespaces) {
*/ */
function load() { function load() {
return process.env.DEBUG; return process.env.DEBUG;
}
/**
* Copied from `node/src/node.js`.
*
* XXX: It's lame that node doesn't expose this API out-of-the-box. It also
* relies on the undocumented `tty_wrap.guessHandleType()` which is also lame.
*/
function createWritableStdioStream (fd) {
var stream;
var tty_wrap = process.binding('tty_wrap');
// Note stream._type is used for test-module-load-list.js
switch (tty_wrap.guessHandleType(fd)) {
case 'TTY':
stream = new tty.WriteStream(fd);
stream._type = 'tty';
// Hack to have stream not keep the event loop alive.
// See https://github.com/joyent/node/issues/1726
if (stream._handle && stream._handle.unref) {
stream._handle.unref();
}
break;
case 'FILE':
var fs = require('fs');
stream = new fs.SyncWriteStream(fd, { autoClose: false });
stream._type = 'fs';
break;
case 'PIPE':
case 'TCP':
var net = require('net');
stream = new net.Socket({
fd: fd,
readable: false,
writable: true
});
// FIXME Should probably have an option in net.Socket to create a
// stream from an existing fd which is writable only. But for now
// we'll just add this hack and set the `readable` member to false.
// Test: ./node test/fixtures/echo.js < /etc/passwd
stream.readable = false;
stream.read = null;
stream._type = 'pipe';
// FIXME Hack to have stream not keep the event loop alive.
// See https://github.com/joyent/node/issues/1726
if (stream._handle && stream._handle.unref) {
stream._handle.unref();
}
break;
default:
// Probably an error on in uv_guess_handle()
throw new Error('Implement me. Unknown stream file type!');
}
// For supporting legacy API we put the FD here.
stream.fd = fd;
stream._isStdio = true;
return stream;
} }
/** /**
@ -232,17 +224,34 @@ function createWritableStdioStream (fd) {
* differently for a particular `debug` instance. * differently for a particular `debug` instance.
*/ */
function init (debug) { function init(debug) {
debug.inspectOpts = {}; debug.inspectOpts = {};
var keys = Object.keys(exports.inspectOpts); const keys = Object.keys(exports.inspectOpts);
for (var i = 0; i < keys.length; i++) { for (let i = 0; i < keys.length; i++) {
debug.inspectOpts[keys[i]] = exports.inspectOpts[keys[i]]; debug.inspectOpts[keys[i]] = exports.inspectOpts[keys[i]];
} }
} }
module.exports = require('./common')(exports);
const {formatters} = module.exports;
/**
* Map %o to `util.inspect()`, all on a single line.
*/
formatters.o = function (v) {
this.inspectOpts.colors = this.useColors;
return util.inspect(v, this.inspectOpts)
.replace(/\s*\n\s*/g, ' ');
};
/** /**
* Enable namespaces listed in `process.env.DEBUG` initially. * Map %O to `util.inspect()`, allowing multiple lines if needed.
*/ */
exports.enable(load()); formatters.O = function (v) {
this.inspectOpts.colors = this.useColors;
return util.inspect(v, this.inspectOpts);
};

3
node_modules/depd/package.json generated vendored

@ -19,13 +19,12 @@
"/body-parser", "/body-parser",
"/express", "/express",
"/http-errors", "/http-errors",
"/morgan",
"/send" "/send"
], ],
"_resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", "_resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz",
"_shasum": "9bcd52e14c097763e749b274c4346ed2e560b5a9", "_shasum": "9bcd52e14c097763e749b274c4346ed2e560b5a9",
"_spec": "depd@~1.1.2", "_spec": "depd@~1.1.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"author": { "author": {
"name": "Douglas Christopher Wilson", "name": "Douglas Christopher Wilson",
"email": "doug@somethingdoug.com" "email": "doug@somethingdoug.com"

2
node_modules/destroy/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", "_resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz",
"_shasum": "978857442c44749e4206613e37946205826abd80", "_shasum": "978857442c44749e4206613e37946205826abd80",
"_spec": "destroy@~1.0.4", "_spec": "destroy@~1.0.4",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/send", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/send",
"author": { "author": {
"name": "Jonathan Ong", "name": "Jonathan Ong",
"email": "me@jongleberry.com", "email": "me@jongleberry.com",

2
node_modules/ee-first/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", "_resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz",
"_shasum": "590c61156b0ae2f4f0255732a158b266bc56b21d", "_shasum": "590c61156b0ae2f4f0255732a158b266bc56b21d",
"_spec": "ee-first@1.1.1", "_spec": "ee-first@1.1.1",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/on-finished", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/on-finished",
"author": { "author": {
"name": "Jonathan Ong", "name": "Jonathan Ong",
"email": "me@jongleberry.com", "email": "me@jongleberry.com",

2
node_modules/encodeurl/package.json generated vendored

@ -24,7 +24,7 @@
"_resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", "_resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz",
"_shasum": "ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59", "_shasum": "ad3ff4c86ec2d029322f5a02c3a9a606c95b3f59",
"_spec": "encodeurl@~1.0.2", "_spec": "encodeurl@~1.0.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"bugs": { "bugs": {
"url": "https://github.com/pillarjs/encodeurl/issues" "url": "https://github.com/pillarjs/encodeurl/issues"
}, },

2
node_modules/escape-html/package.json generated vendored

@ -24,7 +24,7 @@
"_resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", "_resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz",
"_shasum": "0258eae4d3d0c0974de1c169188ef0051d1d1988", "_shasum": "0258eae4d3d0c0974de1c169188ef0051d1d1988",
"_spec": "escape-html@~1.0.3", "_spec": "escape-html@~1.0.3",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"bugs": { "bugs": {
"url": "https://github.com/component/escape-html/issues" "url": "https://github.com/component/escape-html/issues"
}, },

2
node_modules/etag/package.json generated vendored

@ -22,7 +22,7 @@
"_resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", "_resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz",
"_shasum": "41ae2eeb65efa62268aebfea83ac7d79299b0887", "_shasum": "41ae2eeb65efa62268aebfea83ac7d79299b0887",
"_spec": "etag@~1.8.1", "_spec": "etag@~1.8.1",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/etag/issues" "url": "https://github.com/jshttp/etag/issues"
}, },

74
node_modules/express/History.md generated vendored

@ -1,3 +1,59 @@
4.17.1 / 2019-05-25
===================
* Revert "Improve error message for `null`/`undefined` to `res.status`"
4.17.0 / 2019-05-16
===================
* Add `express.raw` to parse bodies into `Buffer`
* Add `express.text` to parse bodies into string
* Improve error message for non-strings to `res.sendFile`
* Improve error message for `null`/`undefined` to `res.status`
* Support multiple hosts in `X-Forwarded-Host`
* deps: accepts@~1.3.7
* deps: body-parser@1.19.0
- Add encoding MIK
- Add petabyte (`pb`) support
- Fix parsing array brackets after index
- deps: bytes@3.1.0
- deps: http-errors@1.7.2
- deps: iconv-lite@0.4.24
- deps: qs@6.7.0
- deps: raw-body@2.4.0
- deps: type-is@~1.6.17
* deps: content-disposition@0.5.3
* deps: cookie@0.4.0
- Add `SameSite=None` support
* deps: finalhandler@~1.1.2
- Set stricter `Content-Security-Policy` header
- deps: parseurl@~1.3.3
- deps: statuses@~1.5.0
* deps: parseurl@~1.3.3
* deps: proxy-addr@~2.0.5
- deps: ipaddr.js@1.9.0
* deps: qs@6.7.0
- Fix parsing array brackets after index
* deps: range-parser@~1.2.1
* deps: send@0.17.1
- Set stricter CSP header in redirect & error responses
- deps: http-errors@~1.7.2
- deps: mime@1.6.0
- deps: ms@2.1.1
- deps: range-parser@~1.2.1
- deps: statuses@~1.5.0
- perf: remove redundant `path.normalize` call
* deps: serve-static@1.14.1
- Set stricter CSP header in redirect response
- deps: parseurl@~1.3.3
- deps: send@0.17.1
* deps: setprototypeof@1.1.1
* deps: statuses@~1.5.0
- Add `103 Early Hints`
* deps: type-is@~1.6.18
- deps: mime-types@~2.1.24
- perf: prevent internal `throw` on invalid type
4.16.4 / 2018-10-10 4.16.4 / 2018-10-10
=================== ===================
@ -294,7 +350,7 @@
- Fix including type extensions in parameters in `Accept` parsing - Fix including type extensions in parameters in `Accept` parsing
- Fix parsing `Accept` parameters with quoted equals - Fix parsing `Accept` parameters with quoted equals
- Fix parsing `Accept` parameters with quoted semicolons - Fix parsing `Accept` parameters with quoted semicolons
- Many performance improvments - Many performance improvements
- deps: mime-types@~2.1.11 - deps: mime-types@~2.1.11
- deps: negotiator@0.6.1 - deps: negotiator@0.6.1
* deps: content-type@~1.0.2 * deps: content-type@~1.0.2
@ -309,7 +365,7 @@
- perf: enable strict mode - perf: enable strict mode
- perf: hoist regular expression - perf: hoist regular expression
- perf: use for loop in parse - perf: use for loop in parse
- perf: use string concatination for serialization - perf: use string concatenation for serialization
* deps: finalhandler@0.5.0 * deps: finalhandler@0.5.0
- Change invalid or non-numeric status code to 500 - Change invalid or non-numeric status code to 500
- Overwrite status message to match set status code - Overwrite status message to match set status code
@ -319,7 +375,7 @@
* deps: proxy-addr@~1.1.2 * deps: proxy-addr@~1.1.2
- Fix accepting various invalid netmasks - Fix accepting various invalid netmasks
- Fix IPv6-mapped IPv4 validation edge cases - Fix IPv6-mapped IPv4 validation edge cases
- IPv4 netmasks must be contingous - IPv4 netmasks must be contiguous
- IPv6 addresses cannot be used as a netmask - IPv6 addresses cannot be used as a netmask
- deps: ipaddr.js@1.1.1 - deps: ipaddr.js@1.1.1
* deps: qs@6.2.0 * deps: qs@6.2.0
@ -1097,13 +1153,13 @@
- deps: negotiator@0.4.6 - deps: negotiator@0.4.6
* deps: debug@1.0.2 * deps: debug@1.0.2
* deps: send@0.4.3 * deps: send@0.4.3
- Do not throw un-catchable error on file open race condition - Do not throw uncatchable error on file open race condition
- Use `escape-html` for HTML escaping - Use `escape-html` for HTML escaping
- deps: debug@1.0.2 - deps: debug@1.0.2
- deps: finished@1.2.2 - deps: finished@1.2.2
- deps: fresh@0.2.2 - deps: fresh@0.2.2
* deps: serve-static@1.2.3 * deps: serve-static@1.2.3
- Do not throw un-catchable error on file open race condition - Do not throw uncatchable error on file open race condition
- deps: send@0.4.3 - deps: send@0.4.3
4.4.2 / 2014-06-09 4.4.2 / 2014-06-09
@ -1983,7 +2039,7 @@
- deps: serve-static@1.2.3 - deps: serve-static@1.2.3
* deps: debug@1.0.2 * deps: debug@1.0.2
* deps: send@0.4.3 * deps: send@0.4.3
- Do not throw un-catchable error on file open race condition - Do not throw uncatchable error on file open race condition
- Use `escape-html` for HTML escaping - Use `escape-html` for HTML escaping
- deps: debug@1.0.2 - deps: debug@1.0.2
- deps: finished@1.2.2 - deps: finished@1.2.2
@ -3168,7 +3224,7 @@ Shaw]
* Updated haml submodule * Updated haml submodule
* Changed ETag; removed inode, modified time only * Changed ETag; removed inode, modified time only
* Fixed LF to CRLF for setting multiple cookies * Fixed LF to CRLF for setting multiple cookies
* Fixed cookie complation; values are now urlencoded * Fixed cookie compilation; values are now urlencoded
* Fixed cookies parsing; accepts quoted values and url escaped cookies * Fixed cookies parsing; accepts quoted values and url escaped cookies
0.11.0 / 2010-05-06 0.11.0 / 2010-05-06
@ -3363,7 +3419,7 @@ Shaw]
* Added "plot" format option for Profiler (for gnuplot processing) * Added "plot" format option for Profiler (for gnuplot processing)
* Added request number to Profiler plugin * Added request number to Profiler plugin
* Fixed binary encoding for multi-part file uploads, was previously defaulting to UTF8 * Fixed binary encoding for multipart file uploads, was previously defaulting to UTF8
* Fixed issue with routes not firing when not files are present. Closes #184 * Fixed issue with routes not firing when not files are present. Closes #184
* Fixed process.Promise -> events.Promise * Fixed process.Promise -> events.Promise
@ -3409,7 +3465,7 @@ Shaw]
* Updated sample chat app to show messages on load * Updated sample chat app to show messages on load
* Updated libxmljs parseString -> parseHtmlString * Updated libxmljs parseString -> parseHtmlString
* Fixed `make init` to work with older versions of git * Fixed `make init` to work with older versions of git
* Fixed specs can now run independent specs for those who cant build deps. Closes #127 * Fixed specs can now run independent specs for those who can't build deps. Closes #127
* Fixed issues introduced by the node url module changes. Closes 126. * Fixed issues introduced by the node url module changes. Closes 126.
* Fixed two assertions failing due to Collection#keys() returning strings * Fixed two assertions failing due to Collection#keys() returning strings
* Fixed faulty Collection#toArray() spec due to keys() returning strings * Fixed faulty Collection#toArray() spec due to keys() returning strings

14
node_modules/express/Readme.md generated vendored

@ -9,8 +9,8 @@
[![Test Coverage][coveralls-image]][coveralls-url] [![Test Coverage][coveralls-image]][coveralls-url]
```js ```js
var express = require('express') const express = require('express')
var app = express() const app = express()
app.get('/', function (req, res) { app.get('/', function (req, res) {
res.send('Hello World') res.send('Hello World')
@ -90,6 +90,8 @@ $ npm install
$ npm start $ npm start
``` ```
View the website at: http://localhost:3000
## Philosophy ## Philosophy
The Express philosophy is to provide small, robust tooling for HTTP servers, making The Express philosophy is to provide small, robust tooling for HTTP servers, making
@ -125,6 +127,10 @@ $ npm install
$ npm test $ npm test
``` ```
## Contributing
[Contributing Guide](Contributing.md)
## People ## People
The original author of Express is [TJ Holowaychuk](https://github.com/tj) The original author of Express is [TJ Holowaychuk](https://github.com/tj)
@ -147,7 +153,3 @@ The current lead maintainer is [Douglas Christopher Wilson](https://github.com/d
[appveyor-url]: https://ci.appveyor.com/project/dougwilson/express [appveyor-url]: https://ci.appveyor.com/project/dougwilson/express
[coveralls-image]: https://img.shields.io/coveralls/expressjs/express/master.svg [coveralls-image]: https://img.shields.io/coveralls/expressjs/express/master.svg
[coveralls-url]: https://coveralls.io/r/expressjs/express?branch=master [coveralls-url]: https://coveralls.io/r/expressjs/express?branch=master
[gratipay-image-visionmedia]: https://img.shields.io/gratipay/visionmedia.svg
[gratipay-url-visionmedia]: https://gratipay.com/visionmedia/
[gratipay-image-dougwilson]: https://img.shields.io/gratipay/dougwilson.svg
[gratipay-url-dougwilson]: https://gratipay.com/dougwilson/

2
node_modules/express/lib/express.js generated vendored

@ -77,7 +77,9 @@ exports.Router = Router;
exports.json = bodyParser.json exports.json = bodyParser.json
exports.query = require('./middleware/query'); exports.query = require('./middleware/query');
exports.raw = bodyParser.raw
exports.static = require('serve-static'); exports.static = require('serve-static');
exports.text = bodyParser.text
exports.urlencoded = bodyParser.urlencoded exports.urlencoded = bodyParser.urlencoded
/** /**

4
node_modules/express/lib/request.js generated vendored

@ -430,6 +430,10 @@ defineGetter(req, 'hostname', function hostname(){
if (!host || !trust(this.connection.remoteAddress, 0)) { if (!host || !trust(this.connection.remoteAddress, 0)) {
host = this.get('Host'); host = this.get('Host');
} else if (host.indexOf(',') !== -1) {
// Note: X-Forwarded-Host is normally only ever a
// single value, but this is to be safe.
host = host.substring(0, host.indexOf(',')).trimRight()
} }
if (!host) return; if (!host) return;

7
node_modules/express/lib/response.js generated vendored

@ -411,6 +411,10 @@ res.sendFile = function sendFile(path, options, callback) {
throw new TypeError('path argument is required to res.sendFile'); throw new TypeError('path argument is required to res.sendFile');
} }
if (typeof path !== 'string') {
throw new TypeError('path must be a string to res.sendFile')
}
// support function as second arg // support function as second arg
if (typeof options === 'function') { if (typeof options === 'function') {
done = options; done = options;
@ -814,7 +818,7 @@ res.clearCookie = function clearCookie(name, options) {
* // "Remember Me" for 15 minutes * // "Remember Me" for 15 minutes
* res.cookie('rememberme', '1', { expires: new Date(Date.now() + 900000), httpOnly: true }); * res.cookie('rememberme', '1', { expires: new Date(Date.now() + 900000), httpOnly: true });
* *
* // save as above * // same as above
* res.cookie('rememberme', '1', { maxAge: 900000, httpOnly: true }) * res.cookie('rememberme', '1', { maxAge: 900000, httpOnly: true })
* *
* @param {String} name * @param {String} name
@ -1127,6 +1131,7 @@ function stringify (value, replacer, spaces, escape) {
return '\\u003e' return '\\u003e'
case 0x26: case 0x26:
return '\\u0026' return '\\u0026'
/* istanbul ignore next: unreachable default */
default: default:
return c return c
} }

62
node_modules/express/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "express@~4.16.1", "_from": "express@^4.17.1",
"_id": "express@4.16.4", "_id": "express@4.17.1",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-j12Uuyb4FMrd/qQAm6uCHAkPtO8FDTRJZBDd5D2KOL2eLaz1yUNdUB/NOIyq0iU4q4cFarsUCrnFDPBcnksuOg==", "_integrity": "sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==",
"_location": "/express", "_location": "/express",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "express@~4.16.1", "raw": "express@^4.17.1",
"name": "express", "name": "express",
"escapedName": "express", "escapedName": "express",
"rawSpec": "~4.16.1", "rawSpec": "^4.17.1",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~4.16.1" "fetchSpec": "^4.17.1"
}, },
"_requiredBy": [ "_requiredBy": [
"/" "/"
], ],
"_resolved": "https://registry.npmjs.org/express/-/express-4.16.4.tgz", "_resolved": "https://registry.npmjs.org/express/-/express-4.17.1.tgz",
"_shasum": "fddef61926109e24c515ea97fd2f1bdbf62df12e", "_shasum": "4491fc38605cf51f8629d39c2b5d026f98a4c134",
"_spec": "express@~4.16.1", "_spec": "express@^4.17.1",
"_where": "/home/f2256342/forge/es6-nodejs", "_where": "/home/yutsuo/forge/nodejs/es6-express",
"author": { "author": {
"name": "TJ Holowaychuk", "name": "TJ Holowaychuk",
"email": "tj@vision-media.ca" "email": "tj@vision-media.ca"
@ -61,34 +61,34 @@
} }
], ],
"dependencies": { "dependencies": {
"accepts": "~1.3.5", "accepts": "~1.3.7",
"array-flatten": "1.1.1", "array-flatten": "1.1.1",
"body-parser": "1.18.3", "body-parser": "1.19.0",
"content-disposition": "0.5.2", "content-disposition": "0.5.3",
"content-type": "~1.0.4", "content-type": "~1.0.4",
"cookie": "0.3.1", "cookie": "0.4.0",
"cookie-signature": "1.0.6", "cookie-signature": "1.0.6",
"debug": "2.6.9", "debug": "2.6.9",
"depd": "~1.1.2", "depd": "~1.1.2",
"encodeurl": "~1.0.2", "encodeurl": "~1.0.2",
"escape-html": "~1.0.3", "escape-html": "~1.0.3",
"etag": "~1.8.1", "etag": "~1.8.1",
"finalhandler": "1.1.1", "finalhandler": "~1.1.2",
"fresh": "0.5.2", "fresh": "0.5.2",
"merge-descriptors": "1.0.1", "merge-descriptors": "1.0.1",
"methods": "~1.1.2", "methods": "~1.1.2",
"on-finished": "~2.3.0", "on-finished": "~2.3.0",
"parseurl": "~1.3.2", "parseurl": "~1.3.3",
"path-to-regexp": "0.1.7", "path-to-regexp": "0.1.7",
"proxy-addr": "~2.0.4", "proxy-addr": "~2.0.5",
"qs": "6.5.2", "qs": "6.7.0",
"range-parser": "~1.2.0", "range-parser": "~1.2.1",
"safe-buffer": "5.1.2", "safe-buffer": "5.1.2",
"send": "0.16.2", "send": "0.17.1",
"serve-static": "1.13.2", "serve-static": "1.14.1",
"setprototypeof": "1.1.0", "setprototypeof": "1.1.1",
"statuses": "~1.4.0", "statuses": "~1.5.0",
"type-is": "~1.6.16", "type-is": "~1.6.18",
"utils-merge": "1.0.1", "utils-merge": "1.0.1",
"vary": "~1.1.2" "vary": "~1.1.2"
}, },
@ -96,15 +96,15 @@
"description": "Fast, unopinionated, minimalist web framework", "description": "Fast, unopinionated, minimalist web framework",
"devDependencies": { "devDependencies": {
"after": "0.8.2", "after": "0.8.2",
"connect-redis": "3.4.0", "connect-redis": "3.4.1",
"cookie-parser": "~1.4.3", "cookie-parser": "~1.4.4",
"cookie-session": "1.3.2", "cookie-session": "1.3.3",
"ejs": "2.6.1", "ejs": "2.6.1",
"eslint": "2.13.1", "eslint": "2.13.1",
"express-session": "1.15.6", "express-session": "1.16.1",
"hbs": "4.0.1", "hbs": "4.0.4",
"istanbul": "0.4.5", "istanbul": "0.4.5",
"marked": "0.5.1", "marked": "0.6.2",
"method-override": "3.0.0", "method-override": "3.0.0",
"mocha": "5.2.0", "mocha": "5.2.0",
"morgan": "1.9.1", "morgan": "1.9.1",
@ -149,5 +149,5 @@
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require test/support/env --reporter dot --check-leaks test/ test/acceptance/", "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require test/support/env --reporter dot --check-leaks test/ test/acceptance/",
"test-tap": "mocha --require test/support/env --reporter tap --check-leaks test/ test/acceptance/" "test-tap": "mocha --require test/support/env --reporter tap --check-leaks test/ test/acceptance/"
}, },
"version": "4.16.4" "version": "4.17.1"
} }

7
node_modules/finalhandler/HISTORY.md generated vendored

@ -1,3 +1,10 @@
1.1.2 / 2019-05-09
==================
* Set stricter `Content-Security-Policy` header
* deps: parseurl@~1.3.3
* deps: statuses@~1.5.0
1.1.1 / 2018-03-06 1.1.1 / 2018-03-06
================== ==================

2
node_modules/finalhandler/README.md generated vendored

@ -116,7 +116,7 @@ var fs = require('fs')
var http = require('http') var http = require('http')
var server = http.createServer(function (req, res) { var server = http.createServer(function (req, res) {
var done = finalhandler(req, res, {onerror: logerror}) var done = finalhandler(req, res, { onerror: logerror })
fs.readFile('index.html', function (err, buf) { fs.readFile('index.html', function (err, buf) {
if (err) return done(err) if (err) return done(err)

2
node_modules/finalhandler/index.js generated vendored

@ -282,7 +282,7 @@ function send (req, res, status, headers, message) {
setHeaders(res, headers) setHeaders(res, headers)
// security headers // security headers
res.setHeader('Content-Security-Policy', "default-src 'self'") res.setHeader('Content-Security-Policy', "default-src 'none'")
res.setHeader('X-Content-Type-Options', 'nosniff') res.setHeader('X-Content-Type-Options', 'nosniff')
// standard headers // standard headers

50
node_modules/finalhandler/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "finalhandler@1.1.1", "_from": "finalhandler@~1.1.2",
"_id": "finalhandler@1.1.1", "_id": "finalhandler@1.1.2",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-Y1GUDo39ez4aHAw7MysnUD5JzYX+WaIj8I57kO3aEPT1fFRL4sr7mjei97FgnwhAyyzRYmQZaTHb2+9uZ1dPtg==", "_integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==",
"_location": "/finalhandler", "_location": "/finalhandler",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "range",
"registry": true, "registry": true,
"raw": "finalhandler@1.1.1", "raw": "finalhandler@~1.1.2",
"name": "finalhandler", "name": "finalhandler",
"escapedName": "finalhandler", "escapedName": "finalhandler",
"rawSpec": "1.1.1", "rawSpec": "~1.1.2",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "1.1.1" "fetchSpec": "~1.1.2"
}, },
"_requiredBy": [ "_requiredBy": [
"/express" "/express"
], ],
"_resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.1.tgz", "_resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz",
"_shasum": "eebf4ed840079c83f4249038c9d703008301b105", "_shasum": "b7e7d000ffd11938d0fdb053506f6ebabe9f587d",
"_spec": "finalhandler@1.1.1", "_spec": "finalhandler@~1.1.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"author": { "author": {
"name": "Douglas Christopher Wilson", "name": "Douglas Christopher Wilson",
"email": "doug@somethingdoug.com" "email": "doug@somethingdoug.com"
@ -35,25 +35,25 @@
"encodeurl": "~1.0.2", "encodeurl": "~1.0.2",
"escape-html": "~1.0.3", "escape-html": "~1.0.3",
"on-finished": "~2.3.0", "on-finished": "~2.3.0",
"parseurl": "~1.3.2", "parseurl": "~1.3.3",
"statuses": "~1.4.0", "statuses": "~1.5.0",
"unpipe": "~1.0.0" "unpipe": "~1.0.0"
}, },
"deprecated": false, "deprecated": false,
"description": "Node.js final http responder", "description": "Node.js final http responder",
"devDependencies": { "devDependencies": {
"eslint": "4.18.1", "eslint": "5.16.0",
"eslint-config-standard": "11.0.0", "eslint-config-standard": "12.0.0",
"eslint-plugin-import": "2.9.0", "eslint-plugin-import": "2.17.2",
"eslint-plugin-markdown": "1.0.0-beta.6", "eslint-plugin-markdown": "1.0.0",
"eslint-plugin-node": "6.0.1", "eslint-plugin-node": "8.0.1",
"eslint-plugin-promise": "3.6.0", "eslint-plugin-promise": "4.1.1",
"eslint-plugin-standard": "3.0.1", "eslint-plugin-standard": "4.0.0",
"istanbul": "0.4.5", "istanbul": "0.4.5",
"mocha": "2.5.3", "mocha": "6.1.4",
"readable-stream": "2.3.4", "readable-stream": "2.3.6",
"safe-buffer": "5.1.1", "safe-buffer": "5.1.2",
"supertest": "1.1.0" "supertest": "4.0.2"
}, },
"engines": { "engines": {
"node": ">= 0.8" "node": ">= 0.8"
@ -76,5 +76,5 @@
"test-ci": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/", "test-ci": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/" "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/"
}, },
"version": "1.1.1" "version": "1.1.2"
} }

2
node_modules/forwarded/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz", "_resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.1.2.tgz",
"_shasum": "98c23dab1175657b8c0573e8ceccd91b0ff18c84", "_shasum": "98c23dab1175657b8c0573e8ceccd91b0ff18c84",
"_spec": "forwarded@~0.1.2", "_spec": "forwarded@~0.1.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/proxy-addr", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/proxy-addr",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/forwarded/issues" "url": "https://github.com/jshttp/forwarded/issues"
}, },

2
node_modules/fresh/package.json generated vendored

@ -22,7 +22,7 @@
"_resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", "_resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz",
"_shasum": "3d8cadd90d976569fa835ab1f8e4b23a105605a7", "_shasum": "3d8cadd90d976569fa835ab1f8e4b23a105605a7",
"_spec": "fresh@0.5.2", "_spec": "fresh@0.5.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"author": { "author": {
"name": "TJ Holowaychuk", "name": "TJ Holowaychuk",
"email": "tj@vision-media.ca", "email": "tj@vision-media.ca",

19
node_modules/http-errors/HISTORY.md generated vendored

@ -1,10 +1,27 @@
2019-02-18 / 1.7.2
==================
* deps: setprototypeof@1.1.1
2018-09-08 / 1.7.1
==================
* Fix error creating objects in some environments
2018-07-30 / 1.7.0
==================
* Set constructor name when possible
* Use `toidentifier` module to make class names
* deps: statuses@'>= 1.5.0 < 2'
2018-03-29 / 1.6.3 2018-03-29 / 1.6.3
================== ==================
* deps: depd@~1.1.2 * deps: depd@~1.1.2
- perf: remove argument reassignment - perf: remove argument reassignment
* deps: setprototypeof@1.1.0 * deps: setprototypeof@1.1.0
* deps: statuses@'>= 1.3.1 < 2' * deps: statuses@'>= 1.4.0 < 2'
2017-08-04 / 1.6.2 2017-08-04 / 1.6.2
================== ==================

54
node_modules/http-errors/README.md generated vendored

@ -1,8 +1,8 @@
# http-errors # http-errors
[![NPM Version][npm-image]][npm-url] [![NPM Version][npm-version-image]][npm-url]
[![NPM Downloads][downloads-image]][downloads-url] [![NPM Downloads][npm-downloads-image]][node-url]
[![Node.js Version][node-version-image]][node-version-url] [![Node.js Version][node-image]][node-url]
[![Build Status][travis-image]][travis-url] [![Build Status][travis-image]][travis-url]
[![Test Coverage][coveralls-image]][coveralls-url] [![Test Coverage][coveralls-image]][coveralls-url]
@ -35,8 +35,6 @@ app.use(function (req, res, next) {
This is the current API, currently extracted from Koa and subject to change. This is the current API, currently extracted from Koa and subject to change.
All errors inherit from JavaScript `Error` and the exported `createError.HttpError`.
### Error Properties ### Error Properties
- `expose` - can be used to signal if `message` should be sent to the client, - `expose` - can be used to signal if `message` should be sent to the client,
@ -52,6 +50,9 @@ All errors inherit from JavaScript `Error` and the exported `createError.HttpErr
### createError([status], [message], [properties]) ### createError([status], [message], [properties])
Create a new error object with the given message `msg`.
The error object inherits from `createError.HttpError`.
<!-- eslint-disable no-undef, no-unused-vars --> <!-- eslint-disable no-undef, no-unused-vars -->
```js ```js
@ -62,8 +63,36 @@ var err = createError(404, 'This video does not exist!')
- `message` - the message of the error, defaulting to node's text for that status code. - `message` - the message of the error, defaulting to node's text for that status code.
- `properties` - custom properties to attach to the object - `properties` - custom properties to attach to the object
### createError([status], [error], [properties])
Extend the given `error` object with `createError.HttpError`
properties. This will not alter the inheritance of the given
`error` object, and the modified `error` object is the
return value.
<!-- eslint-disable no-redeclare, no-undef, no-unused-vars -->
```js
fs.readFile('foo.txt', function (err, buf) {
if (err) {
if (err.code === 'ENOENT') {
var httpError = createError(404, err, { expose: false })
} else {
var httpError = createError(500, err)
}
}
})
```
- `status` - the status code as a number
- `error` - the error object to extend
- `properties` - custom properties to attach to the object
### new createError\[code || name\](\[msg]\)) ### new createError\[code || name\](\[msg]\))
Create a new error object with the given message `msg`.
The error object inherits from `createError.HttpError`.
<!-- eslint-disable no-undef, no-unused-vars --> <!-- eslint-disable no-undef, no-unused-vars -->
```js ```js
@ -123,13 +152,12 @@ var err = new createError.NotFound()
[MIT](LICENSE) [MIT](LICENSE)
[npm-image]: https://img.shields.io/npm/v/http-errors.svg [coveralls-image]: https://badgen.net/coveralls/c/github/jshttp/http-errors/master
[coveralls-url]: https://coveralls.io/r/jshttp/http-errors?branch=master
[node-image]: https://badgen.net/npm/node/http-errors
[node-url]: https://nodejs.org/en/download
[npm-downloads-image]: https://badgen.net/npm/dm/http-errors
[npm-url]: https://npmjs.org/package/http-errors [npm-url]: https://npmjs.org/package/http-errors
[node-version-image]: https://img.shields.io/node/v/http-errors.svg [npm-version-image]: https://badgen.net/npm/v/http-errors
[node-version-url]: https://nodejs.org/en/download/ [travis-image]: https://badgen.net/travis/jshttp/http-errors/master
[travis-image]: https://img.shields.io/travis/jshttp/http-errors.svg
[travis-url]: https://travis-ci.org/jshttp/http-errors [travis-url]: https://travis-ci.org/jshttp/http-errors
[coveralls-image]: https://img.shields.io/coveralls/jshttp/http-errors.svg
[coveralls-url]: https://coveralls.io/r/jshttp/http-errors
[downloads-image]: https://img.shields.io/npm/dm/http-errors.svg
[downloads-url]: https://npmjs.org/package/http-errors

28
node_modules/http-errors/index.js generated vendored

@ -16,6 +16,7 @@ var deprecate = require('depd')('http-errors')
var setPrototypeOf = require('setprototypeof') var setPrototypeOf = require('setprototypeof')
var statuses = require('statuses') var statuses = require('statuses')
var inherits = require('inherits') var inherits = require('inherits')
var toIdentifier = require('toidentifier')
/** /**
* Module exports. * Module exports.
@ -162,6 +163,7 @@ function createClientErrorConstructor (HttpError, name, code) {
} }
inherits(ClientError, HttpError) inherits(ClientError, HttpError)
nameFunc(ClientError, className)
ClientError.prototype.status = code ClientError.prototype.status = code
ClientError.prototype.statusCode = code ClientError.prototype.statusCode = code
@ -209,6 +211,7 @@ function createServerErrorConstructor (HttpError, name, code) {
} }
inherits(ServerError, HttpError) inherits(ServerError, HttpError)
nameFunc(ServerError, className)
ServerError.prototype.status = code ServerError.prototype.status = code
ServerError.prototype.statusCode = code ServerError.prototype.statusCode = code
@ -217,6 +220,20 @@ function createServerErrorConstructor (HttpError, name, code) {
return ServerError return ServerError
} }
/**
* Set the name of a function, if possible.
* @private
*/
function nameFunc (func, name) {
var desc = Object.getOwnPropertyDescriptor(func, 'name')
if (desc && desc.configurable) {
desc.value = name
Object.defineProperty(func, 'name', desc)
}
}
/** /**
* Populate the exports object with constructors for every error class. * Populate the exports object with constructors for every error class.
* @private * @private
@ -247,14 +264,3 @@ function populateConstructorExports (exports, codes, HttpError) {
exports["I'mateapot"] = deprecate.function(exports.ImATeapot, exports["I'mateapot"] = deprecate.function(exports.ImATeapot,
'"I\'mateapot"; use "ImATeapot" instead') '"I\'mateapot"; use "ImATeapot" instead')
} }
/**
* Convert a string of words to a JavaScript identifier.
* @private
*/
function toIdentifier (str) {
return str.split(' ').map(function (token) {
return token.slice(0, 1).toUpperCase() + token.slice(1)
}).join('').replace(/[^ _0-9a-z]/gi, '')
}

47
node_modules/http-errors/package.json generated vendored

@ -1,29 +1,29 @@
{ {
"_from": "http-errors@~1.6.3", "_from": "http-errors@1.7.2",
"_id": "http-errors@1.6.3", "_id": "http-errors@1.7.2",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha1-i1VoC7S+KDoLW/TqLjhYC+HZMg0=", "_integrity": "sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==",
"_location": "/http-errors", "_location": "/http-errors",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "range", "type": "version",
"registry": true, "registry": true,
"raw": "http-errors@~1.6.3", "raw": "http-errors@1.7.2",
"name": "http-errors", "name": "http-errors",
"escapedName": "http-errors", "escapedName": "http-errors",
"rawSpec": "~1.6.3", "rawSpec": "1.7.2",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~1.6.3" "fetchSpec": "1.7.2"
}, },
"_requiredBy": [ "_requiredBy": [
"/body-parser", "/body-parser",
"/raw-body", "/raw-body",
"/send" "/send"
], ],
"_resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.6.3.tgz", "_resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz",
"_shasum": "8b55680bb4be283a0b5bf4ea2e38580be1d9320d", "_shasum": "4f5029cf13239f31036e5b2e55292bcfbcc85c8f",
"_spec": "http-errors@~1.6.3", "_spec": "http-errors@1.7.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/body-parser", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/body-parser",
"author": { "author": {
"name": "Jonathan Ong", "name": "Jonathan Ong",
"email": "me@jongleberry.com", "email": "me@jongleberry.com",
@ -46,21 +46,22 @@
"dependencies": { "dependencies": {
"depd": "~1.1.2", "depd": "~1.1.2",
"inherits": "2.0.3", "inherits": "2.0.3",
"setprototypeof": "1.1.0", "setprototypeof": "1.1.1",
"statuses": ">= 1.4.0 < 2" "statuses": ">= 1.5.0 < 2",
"toidentifier": "1.0.0"
}, },
"deprecated": false, "deprecated": false,
"description": "Create HTTP error objects", "description": "Create HTTP error objects",
"devDependencies": { "devDependencies": {
"eslint": "4.18.1", "eslint": "5.13.0",
"eslint-config-standard": "11.0.0", "eslint-config-standard": "12.0.0",
"eslint-plugin-import": "2.9.0", "eslint-plugin-import": "2.16.0",
"eslint-plugin-markdown": "1.0.0-beta.6", "eslint-plugin-markdown": "1.0.0",
"eslint-plugin-node": "6.0.1", "eslint-plugin-node": "7.0.1",
"eslint-plugin-promise": "3.6.0", "eslint-plugin-promise": "4.0.1",
"eslint-plugin-standard": "3.0.1", "eslint-plugin-standard": "4.0.0",
"istanbul": "0.4.5", "istanbul": "0.4.5",
"mocha": "1.21.5" "mocha": "5.2.0"
}, },
"engines": { "engines": {
"node": ">= 0.6" "node": ">= 0.6"
@ -83,10 +84,10 @@
"url": "git+https://github.com/jshttp/http-errors.git" "url": "git+https://github.com/jshttp/http-errors.git"
}, },
"scripts": { "scripts": {
"lint": "eslint --plugin markdown --ext js,md .", "lint": "eslint --plugin markdown --ext js,md . && node ./scripts/lint-readme-list.js",
"test": "mocha --reporter spec --bail", "test": "mocha --reporter spec --bail",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot", "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot" "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot"
}, },
"version": "1.6.3" "version": "1.7.2"
} }

23
node_modules/iconv-lite/.travis.yml generated vendored

@ -1,23 +0,0 @@
sudo: false
language: node_js
node_js:
- "0.10"
- "0.11"
- "0.12"
- "iojs"
- "4"
- "6"
- "8"
- "node"
env:
- CXX=g++-4.8
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.8
- g++-4.8

4
node_modules/iconv-lite/Changelog.md generated vendored

@ -1,3 +1,7 @@
# 0.4.24 / 2018-08-22
* Added MIK encoding (#196, by @Ivan-Kalatchev)
# 0.4.23 / 2018-05-07 # 0.4.23 / 2018-05-07

4
node_modules/iconv-lite/encodings/sbcs-codec.js generated vendored

@ -20,10 +20,10 @@ function SBCSCodec(codecOptions, iconv) {
codecOptions.chars = asciiString + codecOptions.chars; codecOptions.chars = asciiString + codecOptions.chars;
} }
this.decodeBuf = new Buffer.from(codecOptions.chars, 'ucs2'); this.decodeBuf = Buffer.from(codecOptions.chars, 'ucs2');
// Encoding buffer. // Encoding buffer.
var encodeBuf = new Buffer.alloc(65536, iconv.defaultCharSingleByte.charCodeAt(0)); var encodeBuf = Buffer.alloc(65536, iconv.defaultCharSingleByte.charCodeAt(0));
for (var i = 0; i < codecOptions.chars.length; i++) for (var i = 0; i < codecOptions.chars.length; i++)
encodeBuf[codecOptions.chars.charCodeAt(i)] = i; encodeBuf[codecOptions.chars.charCodeAt(i)] = i;

5
node_modules/iconv-lite/encodings/sbcs-data.js generated vendored

@ -17,6 +17,11 @@ module.exports = {
"chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№€■ " "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№€■ "
}, },
"mik": {
"type": "_sbcs",
"chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя└┴┬├─┼╣║╚╔╩╦╠═╬┐░▒▓│┤№§╗╝┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ "
},
// Aliases of generated encodings. // Aliases of generated encodings.
"ascii8bit": "ascii", "ascii8bit": "ascii",
"usascii": "ascii", "usascii": "ascii",

24
node_modules/iconv-lite/package.json generated vendored

@ -1,28 +1,28 @@
{ {
"_from": "iconv-lite@0.4.23", "_from": "iconv-lite@0.4.24",
"_id": "iconv-lite@0.4.23", "_id": "iconv-lite@0.4.24",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-neyTUVFtahjf0mB3dZT77u+8O0QB89jFdnBkd5P1JgYPbPaia3gXXOVL2fq8VyU2gMMD7SaN7QukTB/pmXYvDA==", "_integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==",
"_location": "/iconv-lite", "_location": "/iconv-lite",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "iconv-lite@0.4.23", "raw": "iconv-lite@0.4.24",
"name": "iconv-lite", "name": "iconv-lite",
"escapedName": "iconv-lite", "escapedName": "iconv-lite",
"rawSpec": "0.4.23", "rawSpec": "0.4.24",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "0.4.23" "fetchSpec": "0.4.24"
}, },
"_requiredBy": [ "_requiredBy": [
"/body-parser", "/body-parser",
"/raw-body" "/raw-body"
], ],
"_resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.23.tgz", "_resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz",
"_shasum": "297871f63be507adcfbfca715d0cd0eed84e9a63", "_shasum": "2022b4b25fbddc21d2f524974a474aafe733908b",
"_spec": "iconv-lite@0.4.23", "_spec": "iconv-lite@0.4.24",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/body-parser", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/body-parser",
"author": { "author": {
"name": "Alexander Shtuchkin", "name": "Alexander Shtuchkin",
"email": "ashtuchkin@gmail.com" "email": "ashtuchkin@gmail.com"
@ -46,7 +46,7 @@
"iconv": "*", "iconv": "*",
"istanbul": "*", "istanbul": "*",
"mocha": "^3.1.0", "mocha": "^3.1.0",
"request": "~2.81.0", "request": "~2.87.0",
"semver": "*", "semver": "*",
"unorm": "*" "unorm": "*"
}, },
@ -73,5 +73,5 @@
"test": "mocha --reporter spec --grep ." "test": "mocha --reporter spec --grep ."
}, },
"typings": "./lib/index.d.ts", "typings": "./lib/index.d.ts",
"version": "0.4.23" "version": "0.4.24"
} }

7
node_modules/inherits/package.json generated vendored

@ -16,12 +16,15 @@
"fetchSpec": "2.0.3" "fetchSpec": "2.0.3"
}, },
"_requiredBy": [ "_requiredBy": [
"/http-errors" "/chokidar",
"/glob",
"/http-errors",
"/readable-stream"
], ],
"_resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", "_resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz",
"_shasum": "633c2c83e3da42a502f52466022480f4208261de", "_shasum": "633c2c83e3da42a502f52466022480f4208261de",
"_spec": "inherits@2.0.3", "_spec": "inherits@2.0.3",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/http-errors", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/http-errors",
"browser": "./inherits_browser.js", "browser": "./inherits_browser.js",
"bugs": { "bugs": {
"url": "https://github.com/isaacs/inherits/issues" "url": "https://github.com/isaacs/inherits/issues"

2
node_modules/ipaddr.js/README.md generated vendored

@ -173,7 +173,7 @@ addr.octets // => [192, 168, 1, 1]
``` ```
`prefixLengthFromSubnetMask()` will return a CIDR prefix length for a valid IPv4 netmask or `prefixLengthFromSubnetMask()` will return a CIDR prefix length for a valid IPv4 netmask or
false if the netmask is not valid. null if the netmask is not valid.
```js ```js
ipaddr.IPv4.parse('255.255.255.240').prefixLengthFromSubnetMask() == 28 ipaddr.IPv4.parse('255.255.255.240').prefixLengthFromSubnetMask() == 28

15
node_modules/ipaddr.js/lib/ipaddr.js.d.ts generated vendored

@ -1,7 +1,4 @@
declare module "ipaddr.js" { declare module "ipaddr.js" {
type IPv4Range = 'unicast' | 'unspecified' | 'broadcast' | 'multicast' | 'linkLocal' | 'loopback' | 'carrierGradeNat' | 'private' | 'reserved'; type IPv4Range = 'unicast' | 'unspecified' | 'broadcast' | 'multicast' | 'linkLocal' | 'loopback' | 'carrierGradeNat' | 'private' | 'reserved';
type IPv6Range = 'unicast' | 'unspecified' | 'linkLocal' | 'multicast' | 'loopback' | 'uniqueLocal' | 'ipv4Mapped' | 'rfc6145' | 'rfc6052' | '6to4' | 'teredo' | 'reserved'; type IPv6Range = 'unicast' | 'unspecified' | 'linkLocal' | 'multicast' | 'loopback' | 'uniqueLocal' | 'ipv4Mapped' | 'rfc6145' | 'rfc6052' | '6to4' | 'teredo' | 'reserved';
@ -9,23 +6,20 @@ declare module "ipaddr.js" {
[name: string]: [T, number] | [T, number][]; [name: string]: [T, number] | [T, number][];
} }
// Common methods/properties for IPv4 and IPv6 classes. // Common methods/properties for IPv4 and IPv6 classes.
class IP { class IP {
prefixLengthFromSubnetMask(): number | null;
prefixLengthFromSubnetMask(): number | false;
toByteArray(): number[]; toByteArray(): number[];
toNormalizedString(): string; toNormalizedString(): string;
toString(): string; toString(): string;
} }
namespace Address { namespace Address {
export function isValid(addr: string): boolean; export function isValid(addr: string): boolean;
export function fromByteArray(bytes: number[]): IPv4 | IPv6; export function fromByteArray(bytes: number[]): IPv4 | IPv6;
export function parse(addr: string): IPv4 | IPv6; export function parse(addr: string): IPv4 | IPv6;
export function parseCIDR(mask: string): [IPv4 | IPv6, number]; export function parseCIDR(mask: string): [IPv4 | IPv6, number];
export function process(address: string): IPv4 | IPv6; export function process(addr: string): IPv4 | IPv6;
export function subnetMatch(addr: IPv4, rangeList: RangeList<IPv4>, defaultName?: string): string; export function subnetMatch(addr: IPv4, rangeList: RangeList<IPv4>, defaultName?: string): string;
export function subnetMatch(addr: IPv6, rangeList: RangeList<IPv6>, defaultName?: string): string; export function subnetMatch(addr: IPv6, rangeList: RangeList<IPv6>, defaultName?: string): string;
@ -39,6 +33,7 @@ declare module "ipaddr.js" {
static parseCIDR(addr: string): [IPv4, number]; static parseCIDR(addr: string): [IPv4, number];
static subnetMaskFromPrefixLength(prefix: number): IPv4; static subnetMaskFromPrefixLength(prefix: number): IPv4;
constructor(octets: number[]); constructor(octets: number[]);
octets: number[]
kind(): 'ipv4'; kind(): 'ipv4';
match(addr: IPv4, bits: number): boolean; match(addr: IPv4, bits: number): boolean;
@ -55,7 +50,9 @@ declare module "ipaddr.js" {
static parse(addr: string): IPv6; static parse(addr: string): IPv6;
static parseCIDR(addr: string): [IPv6, number]; static parseCIDR(addr: string): [IPv6, number];
static subnetMaskFromPrefixLength(prefix: number): IPv6; static subnetMaskFromPrefixLength(prefix: number): IPv6;
constructor(octets: number[]); constructor(parts: number[]);
parts: number[]
zoneId?: string
isIPv4MappedAddress(): boolean; isIPv4MappedAddress(): boolean;
kind(): 'ipv6'; kind(): 'ipv6';

25
node_modules/ipaddr.js/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "ipaddr.js@1.9.0", "_from": "ipaddr.js@1.9.1",
"_id": "ipaddr.js@1.9.0", "_id": "ipaddr.js@1.9.1",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-M4Sjn6N/+O6/IXSJseKqHoFc+5FdGJ22sXqnjTpdZweHK64MzEPAyQZyEU3R/KRv2GLoa7nNtg/C2Ev6m7z+eA==", "_integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==",
"_location": "/ipaddr.js", "_location": "/ipaddr.js",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "ipaddr.js@1.9.0", "raw": "ipaddr.js@1.9.1",
"name": "ipaddr.js", "name": "ipaddr.js",
"escapedName": "ipaddr.js", "escapedName": "ipaddr.js",
"rawSpec": "1.9.0", "rawSpec": "1.9.1",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "1.9.0" "fetchSpec": "1.9.1"
}, },
"_requiredBy": [ "_requiredBy": [
"/proxy-addr" "/proxy-addr"
], ],
"_resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.0.tgz", "_resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz",
"_shasum": "37df74e430a0e47550fe54a2defe30d8acd95f65", "_shasum": "bff38543eeb8984825079ff3a2a8e6cbd46781b3",
"_spec": "ipaddr.js@1.9.0", "_spec": "ipaddr.js@1.9.1",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/proxy-addr", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/proxy-addr",
"author": { "author": {
"name": "whitequark", "name": "whitequark",
"email": "whitequark@whitequark.org" "email": "whitequark@whitequark.org"
@ -35,7 +35,7 @@
"description": "A library for manipulating IPv4 and IPv6 addresses in JavaScript.", "description": "A library for manipulating IPv4 and IPv6 addresses in JavaScript.",
"devDependencies": { "devDependencies": {
"coffee-script": "~1.12.6", "coffee-script": "~1.12.6",
"nodeunit": ">=0.8.2 <0.8.7", "nodeunit": "^0.11.3",
"uglify-js": "~3.0.19" "uglify-js": "~3.0.19"
}, },
"directories": { "directories": {
@ -46,6 +46,7 @@
}, },
"files": [ "files": [
"lib/", "lib/",
"LICENSE",
"ipaddr.min.js" "ipaddr.min.js"
], ],
"homepage": "https://github.com/whitequark/ipaddr.js#readme", "homepage": "https://github.com/whitequark/ipaddr.js#readme",
@ -65,5 +66,5 @@
"test": "cake build test" "test": "cake build test"
}, },
"types": "./lib/ipaddr.js.d.ts", "types": "./lib/ipaddr.js.d.ts",
"version": "1.9.0" "version": "1.9.1"
} }

2
node_modules/media-typer/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", "_resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz",
"_shasum": "8710d7af0aa626f8fffa1ce00168545263255748", "_shasum": "8710d7af0aa626f8fffa1ce00168545263255748",
"_spec": "media-typer@0.3.0", "_spec": "media-typer@0.3.0",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/type-is", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/type-is",
"author": { "author": {
"name": "Douglas Christopher Wilson", "name": "Douglas Christopher Wilson",
"email": "doug@somethingdoug.com" "email": "doug@somethingdoug.com"

2
node_modules/merge-descriptors/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", "_resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz",
"_shasum": "b00aaa556dd8b44568150ec9d1b953f3f90cbb61", "_shasum": "b00aaa556dd8b44568150ec9d1b953f3f90cbb61",
"_spec": "merge-descriptors@1.0.1", "_spec": "merge-descriptors@1.0.1",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"author": { "author": {
"name": "Jonathan Ong", "name": "Jonathan Ong",
"email": "me@jongleberry.com", "email": "me@jongleberry.com",

2
node_modules/methods/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", "_resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz",
"_shasum": "5529a4d67654134edcc5266656835b0f851afcee", "_shasum": "5529a4d67654134edcc5266656835b0f851afcee",
"_spec": "methods@~1.1.2", "_spec": "methods@~1.1.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"browser": { "browser": {
"http": false "http": false
}, },

7
node_modules/mime-db/HISTORY.md generated vendored

@ -1,3 +1,10 @@
1.44.0 / 2020-04-22
===================
* Add charsets from IANA
* Add extension `.cjs` to `application/node`
* Add new upstream MIME types
1.43.0 / 2020-01-05 1.43.0 / 2020-01-05
=================== ===================

6
node_modules/mime-db/README.md generated vendored

@ -34,11 +34,13 @@ https://cdn.jsdelivr.net/gh/jshttp/mime-db@master/db.json
## Usage ## Usage
<!-- eslint-disable no-unused-vars -->
```js ```js
var db = require('mime-db'); var db = require('mime-db')
// grab data on .js files // grab data on .js files
var data = db['application/javascript']; var data = db['application/javascript']
``` ```
## Data Structure ## Data Structure

134
node_modules/mime-db/db.json generated vendored

@ -4,6 +4,7 @@
}, },
"application/3gpdash-qoe-report+xml": { "application/3gpdash-qoe-report+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/3gpp-ims+xml": { "application/3gpp-ims+xml": {
@ -60,6 +61,14 @@
"source": "iana", "source": "iana",
"compressible": true "compressible": true
}, },
"application/alto-updatestreamcontrol+json": {
"source": "iana",
"compressible": true
},
"application/alto-updatestreamparams+json": {
"source": "iana",
"compressible": true
},
"application/aml": { "application/aml": {
"source": "iana" "source": "iana"
}, },
@ -108,6 +117,9 @@
"compressible": true, "compressible": true,
"extensions": ["dwd"] "extensions": ["dwd"]
}, },
"application/atsc-dynamic-event-message": {
"source": "iana"
},
"application/atsc-held+xml": { "application/atsc-held+xml": {
"source": "iana", "source": "iana",
"compressible": true, "compressible": true,
@ -142,6 +154,7 @@
}, },
"application/beep+xml": { "application/beep+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/calendar+json": { "application/calendar+json": {
@ -159,6 +172,11 @@
"application/cals-1840": { "application/cals-1840": {
"source": "iana" "source": "iana"
}, },
"application/cap+xml": {
"source": "iana",
"charset": "UTF-8",
"compressible": true
},
"application/cbor": { "application/cbor": {
"source": "iana" "source": "iana"
}, },
@ -347,6 +365,9 @@
"compressible": true, "compressible": true,
"extensions": ["dbk"] "extensions": ["dbk"]
}, },
"application/dots+cbor": {
"source": "iana"
},
"application/dskpp+xml": { "application/dskpp+xml": {
"source": "iana", "source": "iana",
"compressible": true "compressible": true
@ -459,10 +480,12 @@
}, },
"application/fhir+json": { "application/fhir+json": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/fhir+xml": { "application/fhir+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/fido.trusted-apps+json": { "application/fido.trusted-apps+json": {
@ -559,6 +582,7 @@
}, },
"application/im-iscomposing+xml": { "application/im-iscomposing+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/index": { "application/index": {
@ -701,6 +725,10 @@
"source": "iana", "source": "iana",
"compressible": true "compressible": true
}, },
"application/lpf+zip": {
"source": "iana",
"compressible": false
},
"application/lxf": { "application/lxf": {
"source": "iana" "source": "iana"
}, },
@ -896,10 +924,12 @@
}, },
"application/msc-ivr+xml": { "application/msc-ivr+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/msc-mixer+xml": { "application/msc-mixer+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/msword": { "application/msword": {
@ -930,10 +960,12 @@
"source": "iana" "source": "iana"
}, },
"application/news-checkgroups": { "application/news-checkgroups": {
"source": "iana" "source": "iana",
"charset": "US-ASCII"
}, },
"application/news-groupinfo": { "application/news-groupinfo": {
"source": "iana" "source": "iana",
"charset": "US-ASCII"
}, },
"application/news-transmission": { "application/news-transmission": {
"source": "iana" "source": "iana"
@ -943,7 +975,8 @@
"compressible": true "compressible": true
}, },
"application/node": { "application/node": {
"source": "iana" "source": "iana",
"extensions": ["cjs"]
}, },
"application/nss": { "application/nss": {
"source": "iana" "source": "iana"
@ -1041,10 +1074,12 @@
}, },
"application/pidf+xml": { "application/pidf+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/pidf-diff+xml": { "application/pidf-diff+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/pkcs10": { "application/pkcs10": {
@ -1096,6 +1131,7 @@
}, },
"application/poc-settings+xml": { "application/poc-settings+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/postscript": { "application/postscript": {
@ -1149,6 +1185,10 @@
"compressible": true, "compressible": true,
"extensions": ["pskcxml"] "extensions": ["pskcxml"]
}, },
"application/pvd+json": {
"source": "iana",
"compressible": true
},
"application/qsig": { "application/qsig": {
"source": "iana" "source": "iana"
}, },
@ -1272,6 +1312,9 @@
"source": "iana", "source": "iana",
"compressible": true "compressible": true
}, },
"application/sbe": {
"source": "iana"
},
"application/sbml+xml": { "application/sbml+xml": {
"source": "iana", "source": "iana",
"compressible": true, "compressible": true,
@ -1320,6 +1363,13 @@
"compressible": true, "compressible": true,
"extensions": ["senmlx"] "extensions": ["senmlx"]
}, },
"application/senml-etch+cbor": {
"source": "iana"
},
"application/senml-etch+json": {
"source": "iana",
"compressible": true
},
"application/senml-exi": { "application/senml-exi": {
"source": "iana" "source": "iana"
}, },
@ -1500,6 +1550,10 @@
"source": "iana", "source": "iana",
"compressible": true "compressible": true
}, },
"application/td+json": {
"source": "iana",
"compressible": true
},
"application/tei+xml": { "application/tei+xml": {
"source": "iana", "source": "iana",
"compressible": true, "compressible": true,
@ -2284,6 +2338,9 @@
"source": "iana", "source": "iana",
"compressible": true "compressible": true
}, },
"application/vnd.dbf": {
"source": "iana"
},
"application/vnd.debian.binary-package": { "application/vnd.debian.binary-package": {
"source": "iana" "source": "iana"
}, },
@ -2368,6 +2425,10 @@
"source": "iana", "source": "iana",
"extensions": ["ait"] "extensions": ["ait"]
}, },
"application/vnd.dvb.dvbisl+xml": {
"source": "iana",
"compressible": true
},
"application/vnd.dvb.dvbj": { "application/vnd.dvb.dvbj": {
"source": "iana" "source": "iana"
}, },
@ -3860,6 +3921,10 @@
"application/vnd.ocf+cbor": { "application/vnd.ocf+cbor": {
"source": "iana" "source": "iana"
}, },
"application/vnd.oci.image.manifest.v1+json": {
"source": "iana",
"compressible": true
},
"application/vnd.oftn.l10n+json": { "application/vnd.oftn.l10n+json": {
"source": "iana", "source": "iana",
"compressible": true "compressible": true
@ -4048,14 +4113,17 @@
}, },
"application/vnd.omads-email+xml": { "application/vnd.omads-email+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/vnd.omads-file+xml": { "application/vnd.omads-file+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/vnd.omads-folder+xml": { "application/vnd.omads-folder+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/vnd.omaloc-supl-init": { "application/vnd.omaloc-supl-init": {
@ -4667,6 +4735,9 @@
"source": "iana", "source": "iana",
"extensions": ["st"] "extensions": ["st"]
}, },
"application/vnd.sar": {
"source": "iana"
},
"application/vnd.sbm.cid": { "application/vnd.sbm.cid": {
"source": "iana" "source": "iana"
}, },
@ -4752,6 +4823,12 @@
"source": "iana", "source": "iana",
"compressible": true "compressible": true
}, },
"application/vnd.shp": {
"source": "iana"
},
"application/vnd.shx": {
"source": "iana"
},
"application/vnd.sigrok.session": { "application/vnd.sigrok.session": {
"source": "iana" "source": "iana"
}, },
@ -4774,6 +4851,9 @@
"source": "iana", "source": "iana",
"extensions": ["teacher"] "extensions": ["teacher"]
}, },
"application/vnd.snesdev-page-table": {
"source": "iana"
},
"application/vnd.software602.filler.form+xml": { "application/vnd.software602.filler.form+xml": {
"source": "iana", "source": "iana",
"compressible": true, "compressible": true,
@ -4904,15 +4984,18 @@
}, },
"application/vnd.syncml+xml": { "application/vnd.syncml+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true, "compressible": true,
"extensions": ["xsm"] "extensions": ["xsm"]
}, },
"application/vnd.syncml.dm+wbxml": { "application/vnd.syncml.dm+wbxml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"extensions": ["bdm"] "extensions": ["bdm"]
}, },
"application/vnd.syncml.dm+xml": { "application/vnd.syncml.dm+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true, "compressible": true,
"extensions": ["xdm"] "extensions": ["xdm"]
}, },
@ -4924,6 +5007,7 @@
}, },
"application/vnd.syncml.dmddf+xml": { "application/vnd.syncml.dmddf+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true, "compressible": true,
"extensions": ["ddf"] "extensions": ["ddf"]
}, },
@ -4932,6 +5016,7 @@
}, },
"application/vnd.syncml.dmtnds+xml": { "application/vnd.syncml.dmtnds+xml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true "compressible": true
}, },
"application/vnd.syncml.ds.notification": { "application/vnd.syncml.ds.notification": {
@ -5100,6 +5185,7 @@
}, },
"application/vnd.wap.wbxml": { "application/vnd.wap.wbxml": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"extensions": ["wbxml"] "extensions": ["wbxml"]
}, },
"application/vnd.wap.wmlc": { "application/vnd.wap.wmlc": {
@ -5696,6 +5782,9 @@
"source": "apache", "source": "apache",
"extensions": ["p7r"] "extensions": ["p7r"]
}, },
"application/x-pki-message": {
"source": "iana"
},
"application/x-rar-compressed": { "application/x-rar-compressed": {
"source": "apache", "source": "apache",
"compressible": false, "compressible": false,
@ -5838,9 +5927,15 @@
"compressible": true "compressible": true
}, },
"application/x-x509-ca-cert": { "application/x-x509-ca-cert": {
"source": "apache", "source": "iana",
"extensions": ["der","crt","pem"] "extensions": ["der","crt","pem"]
}, },
"application/x-x509-ca-ra-cert": {
"source": "iana"
},
"application/x-x509-next-ca-cert": {
"source": "iana"
},
"application/x-xfig": { "application/x-xfig": {
"source": "apache", "source": "apache",
"extensions": ["fig"] "extensions": ["fig"]
@ -6245,6 +6340,9 @@
"audio/melp600": { "audio/melp600": {
"source": "iana" "source": "iana"
}, },
"audio/mhas": {
"source": "iana"
},
"audio/midi": { "audio/midi": {
"source": "apache", "source": "apache",
"extensions": ["mid","midi","kar","rmi"] "extensions": ["mid","midi","kar","rmi"]
@ -6364,6 +6462,9 @@
"audio/tetra_acelp": { "audio/tetra_acelp": {
"source": "iana" "source": "iana"
}, },
"audio/tetra_acelp_bb": {
"source": "iana"
},
"audio/tone": { "audio/tone": {
"source": "iana" "source": "iana"
}, },
@ -7133,6 +7234,14 @@
"compressible": false, "compressible": false,
"extensions": ["msh","mesh","silo"] "extensions": ["msh","mesh","silo"]
}, },
"model/mtl": {
"source": "iana",
"extensions": ["mtl"]
},
"model/obj": {
"source": "iana",
"extensions": ["obj"]
},
"model/stl": { "model/stl": {
"source": "iana", "source": "iana",
"extensions": ["stl"] "extensions": ["stl"]
@ -7380,11 +7489,13 @@
}, },
"text/n3": { "text/n3": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"compressible": true, "compressible": true,
"extensions": ["n3"] "extensions": ["n3"]
}, },
"text/parameters": { "text/parameters": {
"source": "iana" "source": "iana",
"charset": "UTF-8"
}, },
"text/parityfec": { "text/parityfec": {
"source": "iana" "source": "iana"
@ -7395,7 +7506,8 @@
"extensions": ["txt","text","conf","def","list","log","in","ini"] "extensions": ["txt","text","conf","def","list","log","in","ini"]
}, },
"text/provenance-notation": { "text/provenance-notation": {
"source": "iana" "source": "iana",
"charset": "UTF-8"
}, },
"text/prs.fallenstein.rst": { "text/prs.fallenstein.rst": {
"source": "iana" "source": "iana"
@ -7507,7 +7619,8 @@
"extensions": ["scurl"] "extensions": ["scurl"]
}, },
"text/vnd.debian.copyright": { "text/vnd.debian.copyright": {
"source": "iana" "source": "iana",
"charset": "UTF-8"
}, },
"text/vnd.dmclientscript": { "text/vnd.dmclientscript": {
"source": "iana" "source": "iana"
@ -7517,7 +7630,8 @@
"extensions": ["sub"] "extensions": ["sub"]
}, },
"text/vnd.esmertec.theme-descriptor": { "text/vnd.esmertec.theme-descriptor": {
"source": "iana" "source": "iana",
"charset": "UTF-8"
}, },
"text/vnd.ficlab.flt": { "text/vnd.ficlab.flt": {
"source": "iana" "source": "iana"
@ -7580,10 +7694,12 @@
}, },
"text/vnd.sun.j2me.app-descriptor": { "text/vnd.sun.j2me.app-descriptor": {
"source": "iana", "source": "iana",
"charset": "UTF-8",
"extensions": ["jad"] "extensions": ["jad"]
}, },
"text/vnd.trolltech.linguist": { "text/vnd.trolltech.linguist": {
"source": "iana" "source": "iana",
"charset": "UTF-8"
}, },
"text/vnd.wap.si": { "text/vnd.wap.si": {
"source": "iana" "source": "iana"

37
node_modules/mime-db/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "mime-db@1.43.0", "_from": "mime-db@1.44.0",
"_id": "mime-db@1.43.0", "_id": "mime-db@1.44.0",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-+5dsGEEovYbT8UY9yD7eE4XTc4UwJ1jBYlgaQQF38ENsKR3wj/8q8RFZrF9WIZpB2V1ArTVFUva8sAul1NzRzQ==", "_integrity": "sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg==",
"_location": "/mime-db", "_location": "/mime-db",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "mime-db@1.43.0", "raw": "mime-db@1.44.0",
"name": "mime-db", "name": "mime-db",
"escapedName": "mime-db", "escapedName": "mime-db",
"rawSpec": "1.43.0", "rawSpec": "1.44.0",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "1.43.0" "fetchSpec": "1.44.0"
}, },
"_requiredBy": [ "_requiredBy": [
"/mime-types" "/mime-types"
], ],
"_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.43.0.tgz", "_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz",
"_shasum": "0a12e0502650e473d735535050e7c8f4eb4fae58", "_shasum": "fa11c5eb0aca1334b4233cb4d52f10c5a6272f92",
"_spec": "mime-db@1.43.0", "_spec": "mime-db@1.44.0",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/mime-types", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/mime-types",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/mime-db/issues" "url": "https://github.com/jshttp/mime-db/issues"
}, },
@ -48,16 +48,17 @@
"bluebird": "3.7.2", "bluebird": "3.7.2",
"co": "4.6.0", "co": "4.6.0",
"cogent": "1.0.1", "cogent": "1.0.1",
"csv-parse": "4.8.3", "csv-parse": "4.8.9",
"eslint": "6.8.0", "eslint": "6.8.0",
"eslint-config-standard": "14.1.0", "eslint-config-standard": "14.1.1",
"eslint-plugin-import": "2.19.1", "eslint-plugin-import": "2.20.2",
"eslint-plugin-node": "11.0.0", "eslint-plugin-markdown": "1.0.2",
"eslint-plugin-node": "11.1.0",
"eslint-plugin-promise": "4.2.1", "eslint-plugin-promise": "4.2.1",
"eslint-plugin-standard": "4.0.1", "eslint-plugin-standard": "4.0.1",
"gnode": "0.1.2", "gnode": "0.1.2",
"mocha": "7.0.0", "mocha": "7.1.1",
"nyc": "15.0.0", "nyc": "15.0.1",
"raw-body": "2.4.1", "raw-body": "2.4.1",
"stream-to-array": "2.3.0" "stream-to-array": "2.3.0"
}, },
@ -90,12 +91,12 @@
"scripts": { "scripts": {
"build": "node scripts/build", "build": "node scripts/build",
"fetch": "node scripts/fetch-apache && gnode scripts/fetch-iana && node scripts/fetch-nginx", "fetch": "node scripts/fetch-apache && gnode scripts/fetch-iana && node scripts/fetch-nginx",
"lint": "eslint .", "lint": "eslint --plugin markdown --ext js,md .",
"test": "mocha --reporter spec --bail --check-leaks test/", "test": "mocha --reporter spec --bail --check-leaks test/",
"test-cov": "nyc --reporter=html --reporter=text npm test", "test-cov": "nyc --reporter=html --reporter=text npm test",
"test-travis": "nyc --reporter=text npm test", "test-travis": "nyc --reporter=text npm test",
"update": "npm run fetch && npm run build", "update": "npm run fetch && npm run build",
"version": "node scripts/version-history.js && git add HISTORY.md" "version": "node scripts/version-history.js && git add HISTORY.md"
}, },
"version": "1.43.0" "version": "1.44.0"
} }

8
node_modules/mime-types/HISTORY.md generated vendored

@ -1,3 +1,11 @@
2.1.27 / 2020-04-23
===================
* deps: mime-db@1.44.0
- Add charsets from IANA
- Add extension `.cjs` to `application/node`
- Add new upstream MIME types
2.1.26 / 2020-01-05 2.1.26 / 2020-01-05
=================== ===================

20
node_modules/mime-types/README.md generated vendored

@ -36,6 +36,8 @@ so open a PR there if you'd like to add mime types.
## API ## API
<!-- eslint-disable no-unused-vars -->
```js ```js
var mime = require('mime-types') var mime = require('mime-types')
``` ```
@ -46,11 +48,13 @@ All functions return `false` if input is invalid or not found.
Lookup the content-type associated with a file. Lookup the content-type associated with a file.
<!-- eslint-disable no-undef -->
```js ```js
mime.lookup('json') // 'application/json' mime.lookup('json') // 'application/json'
mime.lookup('.md') // 'text/markdown' mime.lookup('.md') // 'text/markdown'
mime.lookup('file.html') // 'text/html' mime.lookup('file.html') // 'text/html'
mime.lookup('folder/file.js') // 'application/javascript' mime.lookup('folder/file.js') // 'application/javascript'
mime.lookup('folder/.htaccess') // false mime.lookup('folder/.htaccess') // false
mime.lookup('cats') // false mime.lookup('cats') // false
@ -64,8 +68,10 @@ content-type, otherwise the given content-type is used. Then if the
content-type does not already have a `charset` parameter, `mime.charset` content-type does not already have a `charset` parameter, `mime.charset`
is used to get the default charset and add to the returned content-type. is used to get the default charset and add to the returned content-type.
<!-- eslint-disable no-undef -->
```js ```js
mime.contentType('markdown') // 'text/x-markdown; charset=utf-8' mime.contentType('markdown') // 'text/x-markdown; charset=utf-8'
mime.contentType('file.json') // 'application/json; charset=utf-8' mime.contentType('file.json') // 'application/json; charset=utf-8'
mime.contentType('text/html') // 'text/html; charset=utf-8' mime.contentType('text/html') // 'text/html; charset=utf-8'
mime.contentType('text/html; charset=iso-8859-1') // 'text/html; charset=iso-8859-1' mime.contentType('text/html; charset=iso-8859-1') // 'text/html; charset=iso-8859-1'
@ -78,6 +84,8 @@ mime.contentType(path.extname('/path/to/file.json')) // 'application/json; chars
Get the default extension for a content-type. Get the default extension for a content-type.
<!-- eslint-disable no-undef -->
```js ```js
mime.extension('application/octet-stream') // 'bin' mime.extension('application/octet-stream') // 'bin'
``` ```
@ -86,6 +94,8 @@ mime.extension('application/octet-stream') // 'bin'
Lookup the implied default charset of a content-type. Lookup the implied default charset of a content-type.
<!-- eslint-disable no-undef -->
```js ```js
mime.charset('text/markdown') // 'UTF-8' mime.charset('text/markdown') // 'UTF-8'
``` ```

27
node_modules/mime-types/package.json generated vendored

@ -1,8 +1,8 @@
{ {
"_from": "mime-types@~2.1.24", "_from": "mime-types@~2.1.24",
"_id": "mime-types@2.1.26", "_id": "mime-types@2.1.27",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-01paPWYgLrkqAyrlDorC1uDwl2p3qZT7yl806vW7DvDoxwXi46jsjFbg+WdwotBIk6/MbEhO/dh5aZ5sNj/dWQ==", "_integrity": "sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w==",
"_location": "/mime-types", "_location": "/mime-types",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
@ -19,10 +19,10 @@
"/accepts", "/accepts",
"/type-is" "/type-is"
], ],
"_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.26.tgz", "_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz",
"_shasum": "9c921fc09b7e149a65dfdc0da4d20997200b0a06", "_shasum": "47949f98e279ea53119f5722e0f34e529bec009f",
"_spec": "mime-types@~2.1.24", "_spec": "mime-types@~2.1.24",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/accepts", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/accepts",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/mime-types/issues" "url": "https://github.com/jshttp/mime-types/issues"
}, },
@ -44,19 +44,20 @@
} }
], ],
"dependencies": { "dependencies": {
"mime-db": "1.43.0" "mime-db": "1.44.0"
}, },
"deprecated": false, "deprecated": false,
"description": "The ultimate javascript content-type utility.", "description": "The ultimate javascript content-type utility.",
"devDependencies": { "devDependencies": {
"eslint": "6.8.0", "eslint": "6.8.0",
"eslint-config-standard": "14.1.0", "eslint-config-standard": "14.1.1",
"eslint-plugin-import": "2.19.1", "eslint-plugin-import": "2.20.2",
"eslint-plugin-node": "11.0.0", "eslint-plugin-markdown": "1.0.2",
"eslint-plugin-node": "11.1.0",
"eslint-plugin-promise": "4.2.1", "eslint-plugin-promise": "4.2.1",
"eslint-plugin-standard": "4.0.1", "eslint-plugin-standard": "4.0.1",
"mocha": "7.0.0", "mocha": "7.1.1",
"nyc": "15.0.0" "nyc": "15.0.1"
}, },
"engines": { "engines": {
"node": ">= 0.6" "node": ">= 0.6"
@ -78,10 +79,10 @@
"url": "git+https://github.com/jshttp/mime-types.git" "url": "git+https://github.com/jshttp/mime-types.git"
}, },
"scripts": { "scripts": {
"lint": "eslint .", "lint": "eslint --plugin markdown --ext js,md .",
"test": "mocha --reporter spec test/test.js", "test": "mocha --reporter spec test/test.js",
"test-cov": "nyc --reporter=html --reporter=text npm test", "test-cov": "nyc --reporter=html --reporter=text npm test",
"test-travis": "nyc --reporter=text npm test" "test-travis": "nyc --reporter=text npm test"
}, },
"version": "2.1.26" "version": "2.1.27"
} }

11
node_modules/mime/build/build.js generated vendored

@ -1,11 +0,0 @@
var db = require('mime-db');
var mapByType = {};
Object.keys(db).forEach(function(key) {
var extensions = db[key].extensions;
if (extensions) {
mapByType[key] = extensions;
}
});
console.log(JSON.stringify(mapByType));

60
node_modules/mime/build/test.js generated vendored

@ -1,60 +0,0 @@
/**
* Usage: node test.js
*/
var mime = require('../mime');
var assert = require('assert');
var path = require('path');
//
// Test mime lookups
//
assert.equal('text/plain', mime.lookup('text.txt')); // normal file
assert.equal('text/plain', mime.lookup('TEXT.TXT')); // uppercase
assert.equal('text/plain', mime.lookup('dir/text.txt')); // dir + file
assert.equal('text/plain', mime.lookup('.text.txt')); // hidden file
assert.equal('text/plain', mime.lookup('.txt')); // nameless
assert.equal('text/plain', mime.lookup('txt')); // extension-only
assert.equal('text/plain', mime.lookup('/txt')); // extension-less ()
assert.equal('text/plain', mime.lookup('\\txt')); // Windows, extension-less
assert.equal('application/octet-stream', mime.lookup('text.nope')); // unrecognized
assert.equal('fallback', mime.lookup('text.fallback', 'fallback')); // alternate default
//
// Test extensions
//
assert.equal('txt', mime.extension(mime.types.text));
assert.equal('html', mime.extension(mime.types.htm));
assert.equal('bin', mime.extension('application/octet-stream'));
assert.equal('bin', mime.extension('application/octet-stream '));
assert.equal('html', mime.extension(' text/html; charset=UTF-8'));
assert.equal('html', mime.extension('text/html; charset=UTF-8 '));
assert.equal('html', mime.extension('text/html; charset=UTF-8'));
assert.equal('html', mime.extension('text/html ; charset=UTF-8'));
assert.equal('html', mime.extension('text/html;charset=UTF-8'));
assert.equal('html', mime.extension('text/Html;charset=UTF-8'));
assert.equal(undefined, mime.extension('unrecognized'));
//
// Test node.types lookups
//
assert.equal('application/font-woff', mime.lookup('file.woff'));
assert.equal('application/octet-stream', mime.lookup('file.buffer'));
// TODO: Uncomment once #157 is resolved
// assert.equal('audio/mp4', mime.lookup('file.m4a'));
assert.equal('font/otf', mime.lookup('file.otf'));
//
// Test charsets
//
assert.equal('UTF-8', mime.charsets.lookup('text/plain'));
assert.equal('UTF-8', mime.charsets.lookup(mime.types.js));
assert.equal('UTF-8', mime.charsets.lookup(mime.types.json));
assert.equal(undefined, mime.charsets.lookup(mime.types.bin));
assert.equal('fallback', mime.charsets.lookup('application/octet-stream', 'fallback'));
console.log('\nAll tests passed');

34
node_modules/mime/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "mime@1.4.1", "_from": "mime@1.6.0",
"_id": "mime@1.4.1", "_id": "mime@1.6.0",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-KI1+qOZu5DcW6wayYHSzR/tXKCDC5Om4s1z2QJjDULzLcmf3DvzS7oluY4HCTrc+9FiKmWUgeNLg7W3uIQvxtQ==", "_integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==",
"_location": "/mime", "_location": "/mime",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "version",
"registry": true, "registry": true,
"raw": "mime@1.4.1", "raw": "mime@1.6.0",
"name": "mime", "name": "mime",
"escapedName": "mime", "escapedName": "mime",
"rawSpec": "1.4.1", "rawSpec": "1.6.0",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "1.4.1" "fetchSpec": "1.6.0"
}, },
"_requiredBy": [ "_requiredBy": [
"/send" "/send"
], ],
"_resolved": "https://registry.npmjs.org/mime/-/mime-1.4.1.tgz", "_resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz",
"_shasum": "121f9ebc49e3766f311a76e1fa1c8003c4b03aa6", "_shasum": "32cd9e5c64553bd58d19a568af452acff04981b1",
"_spec": "mime@1.4.1", "_spec": "mime@1.6.0",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/send", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/send",
"author": { "author": {
"name": "Robert Kieffer", "name": "Robert Kieffer",
"email": "robert@broofa.com", "email": "robert@broofa.com",
@ -45,7 +45,12 @@
"deprecated": false, "deprecated": false,
"description": "A comprehensive library for mime-type mapping", "description": "A comprehensive library for mime-type mapping",
"devDependencies": { "devDependencies": {
"mime-db": "1.30.0" "github-release-notes": "0.13.1",
"mime-db": "1.31.0",
"mime-score": "1.1.0"
},
"engines": {
"node": ">=4"
}, },
"homepage": "https://github.com/broofa/node-mime#readme", "homepage": "https://github.com/broofa/node-mime#readme",
"keywords": [ "keywords": [
@ -60,8 +65,9 @@
"type": "git" "type": "git"
}, },
"scripts": { "scripts": {
"prepublish": "node build/build.js > types.json", "changelog": "gren changelog --tags=all --generate --override",
"test": "node build/test.js" "prepare": "node src/build.js",
"test": "node src/test.js"
}, },
"version": "1.4.1" "version": "1.6.0"
} }

2
node_modules/mime/types.json generated vendored

File diff suppressed because one or more lines are too long

13
node_modules/morgan/HISTORY.md generated vendored

@ -1,3 +1,16 @@
1.10.0 / 2020-03-20
===================
* Add `:total-time` token
* Fix trailing space in colored status code for `dev` format
* deps: basic-auth@~2.0.1
- deps: safe-buffer@5.1.2
* deps: depd@~2.0.0
- Replace internal `eval` usage with `Function` constructor
- Use instance methods on `process` to check for listeners
* deps: on-headers@~1.0.2
- Fix `res.writeHead` patch missing return value
1.9.1 / 2018-09-10 1.9.1 / 2018-09-10
================== ==================

39
node_modules/morgan/README.md generated vendored

@ -1,7 +1,7 @@
# morgan # morgan
[![NPM Version][npm-image]][npm-url] [![NPM Version][npm-version-image]][npm-url]
[![NPM Downloads][downloads-image]][downloads-url] [![NPM Downloads][npm-downloads-image]][npm-url]
[![Build Status][travis-image]][travis-url] [![Build Status][travis-image]][travis-url]
[![Test Coverage][coveralls-image]][coveralls-url] [![Test Coverage][coveralls-image]][coveralls-url]
@ -111,8 +111,9 @@ Standard Apache common log output.
##### dev ##### dev
Concise output colored by response status for development use. The `:status` Concise output colored by response status for development use. The `:status`
token will be colored red for server error codes, yellow for client error token will be colored green for success codes, red for server error codes,
codes, cyan for redirection codes, and uncolored for all other codes. yellow for client error codes, cyan for redirection codes, and uncolored
for information codes.
``` ```
:method :url :status :response-time ms - :res[content-length] :method :url :status :response-time ms - :res[content-length]
@ -211,6 +212,14 @@ If the request/response cycle completes before a response was sent to the
client (for example, the TCP socket closed prematurely by a client aborting client (for example, the TCP socket closed prematurely by a client aborting
the request), then the status will be empty (displayed as `"-"` in the log). the request), then the status will be empty (displayed as `"-"` in the log).
##### :total-time[digits]
The time between the request coming into `morgan` and when the response
has finished being written out to the connection, in milliseconds.
The `digits` argument is a number that specifies the number of digits to
include on the number, defaulting to `3`, which provides microsecond precision.
##### :url ##### :url
The URL of the request. This will use `req.originalUrl` if exists, otherwise `req.url`. The URL of the request. This will use `req.originalUrl` if exists, otherwise `req.url`.
@ -312,21 +321,16 @@ file per day in the `log/` directory using the
```js ```js
var express = require('express') var express = require('express')
var fs = require('fs')
var morgan = require('morgan') var morgan = require('morgan')
var path = require('path') var path = require('path')
var rfs = require('rotating-file-stream') var rfs = require('rotating-file-stream') // version 2.x
var app = express() var app = express()
var logDirectory = path.join(__dirname, 'log')
// ensure log directory exists
fs.existsSync(logDirectory) || fs.mkdirSync(logDirectory)
// create a rotating write stream // create a rotating write stream
var accessLogStream = rfs('access.log', { var accessLogStream = rfs.createStream('access.log', {
interval: '1d', // rotate daily interval: '1d', // rotate daily
path: logDirectory path: path.join(__dirname, 'log')
}) })
// setup the logger // setup the logger
@ -404,11 +408,10 @@ function assignId (req, res, next) {
[MIT](LICENSE) [MIT](LICENSE)
[npm-image]: https://img.shields.io/npm/v/morgan.svg [coveralls-image]: https://badgen.net/coveralls/c/github/expressjs/morgan/master
[coveralls-url]: https://coveralls.io/r/expressjs/morgan?branch=master
[npm-downloads-image]: https://badgen.net/npm/dm/morgan
[npm-url]: https://npmjs.org/package/morgan [npm-url]: https://npmjs.org/package/morgan
[travis-image]: https://img.shields.io/travis/expressjs/morgan/master.svg [npm-version-image]: https://badgen.net/npm/v/morgan
[travis-image]: https://badgen.net/travis/expressjs/morgan/master
[travis-url]: https://travis-ci.org/expressjs/morgan [travis-url]: https://travis-ci.org/expressjs/morgan
[coveralls-image]: https://img.shields.io/coveralls/expressjs/morgan/master.svg
[coveralls-url]: https://coveralls.io/r/expressjs/morgan?branch=master
[downloads-image]: https://img.shields.io/npm/dm/morgan.svg
[downloads-url]: https://npmjs.org/package/morgan

26
node_modules/morgan/index.js generated vendored

@ -199,7 +199,7 @@ morgan.format('dev', function developmentFormatLine (tokens, req, res) {
if (!fn) { if (!fn) {
// compile // compile
fn = developmentFormatLine[color] = compile('\x1b[0m:method :url \x1b[' + fn = developmentFormatLine[color] = compile('\x1b[0m:method :url \x1b[' +
color + 'm:status \x1b[0m:response-time ms - :res[content-length]\x1b[0m') color + 'm:status\x1b[0m :response-time ms - :res[content-length]\x1b[0m')
} }
return fn(tokens, req, res) return fn(tokens, req, res)
@ -239,6 +239,26 @@ morgan.token('response-time', function getResponseTimeToken (req, res, digits) {
return ms.toFixed(digits === undefined ? 3 : digits) return ms.toFixed(digits === undefined ? 3 : digits)
}) })
/**
* total time in milliseconds
*/
morgan.token('total-time', function getTotalTimeToken (req, res, digits) {
if (!req._startAt || !res._startAt) {
// missing request and/or response start time
return
}
// time elapsed from request start
var elapsed = process.hrtime(req._startAt)
// cover to milliseconds
var ms = (elapsed[0] * 1e3) + (elapsed[1] * 1e-6)
// return truncated value
return ms.toFixed(digits === undefined ? 3 : digits)
})
/** /**
* current date * current date
*/ */
@ -271,7 +291,7 @@ morgan.token('status', function getStatusToken (req, res) {
*/ */
morgan.token('referrer', function getReferrerToken (req) { morgan.token('referrer', function getReferrerToken (req) {
return req.headers['referer'] || req.headers['referrer'] return req.headers.referer || req.headers.referrer
}) })
/** /**
@ -478,6 +498,7 @@ function getip (req) {
*/ */
function headersSent (res) { function headersSent (res) {
// istanbul ignore next: node.js 0.8 support
return typeof res.headersSent !== 'boolean' return typeof res.headersSent !== 'boolean'
? Boolean(res._header) ? Boolean(res._header)
: res.headersSent : res.headersSent
@ -494,6 +515,7 @@ function headersSent (res) {
function pad2 (num) { function pad2 (num) {
var str = String(num) var str = String(num)
// istanbul ignore next: num is current datetime
return (str.length === 1 ? '0' : '') + str return (str.length === 1 ? '0' : '') + str
} }

52
node_modules/morgan/package.json generated vendored

@ -1,27 +1,27 @@
{ {
"_from": "morgan@~1.9.1", "_from": "morgan@^1.10.0",
"_id": "morgan@1.9.1", "_id": "morgan@1.10.0",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-HQStPIV4y3afTiCYVxirakhlCfGkI161c76kKFca7Fk1JusM//Qeo1ej2XaMniiNeaZklMVrh3vTtIzpzwbpmA==", "_integrity": "sha512-AbegBVI4sh6El+1gNwvD5YIck7nSA36weD7xvIxG4in80j/UoK8AEGaWnnz8v1GxonMCltmlNs5ZKbGvl9b1XQ==",
"_location": "/morgan", "_location": "/morgan",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "morgan@~1.9.1", "raw": "morgan@^1.10.0",
"name": "morgan", "name": "morgan",
"escapedName": "morgan", "escapedName": "morgan",
"rawSpec": "~1.9.1", "rawSpec": "^1.10.0",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~1.9.1" "fetchSpec": "^1.10.0"
}, },
"_requiredBy": [ "_requiredBy": [
"/" "/"
], ],
"_resolved": "https://registry.npmjs.org/morgan/-/morgan-1.9.1.tgz", "_resolved": "https://registry.npmjs.org/morgan/-/morgan-1.10.0.tgz",
"_shasum": "0a8d16734a1d9afbc824b99df87e738e58e2da59", "_shasum": "091778abc1fc47cd3509824653dae1faab6b17d7",
"_spec": "morgan@~1.9.1", "_spec": "morgan@^1.10.0",
"_where": "/home/f2256342/forge/es6-nodejs", "_where": "/home/yutsuo/forge/nodejs/es6-express",
"bugs": { "bugs": {
"url": "https://github.com/expressjs/morgan/issues" "url": "https://github.com/expressjs/morgan/issues"
}, },
@ -38,26 +38,26 @@
} }
], ],
"dependencies": { "dependencies": {
"basic-auth": "~2.0.0", "basic-auth": "~2.0.1",
"debug": "2.6.9", "debug": "2.6.9",
"depd": "~1.1.2", "depd": "~2.0.0",
"on-finished": "~2.3.0", "on-finished": "~2.3.0",
"on-headers": "~1.0.1" "on-headers": "~1.0.2"
}, },
"deprecated": false, "deprecated": false,
"description": "HTTP request logger middleware for node.js", "description": "HTTP request logger middleware for node.js",
"devDependencies": { "devDependencies": {
"eslint": "5.5.0", "eslint": "6.8.0",
"eslint-config-standard": "12.0.0", "eslint-config-standard": "14.1.0",
"eslint-plugin-import": "2.14.0", "eslint-plugin-import": "2.20.1",
"eslint-plugin-markdown": "1.0.0-beta.6", "eslint-plugin-markdown": "1.0.2",
"eslint-plugin-node": "7.0.1", "eslint-plugin-node": "9.2.0",
"eslint-plugin-promise": "4.0.1", "eslint-plugin-promise": "4.2.1",
"eslint-plugin-standard": "4.0.0", "eslint-plugin-standard": "4.0.1",
"istanbul": "0.4.5", "mocha": "7.1.1",
"mocha": "2.5.3", "nyc": "15.0.0",
"split": "1.0.1", "split": "1.0.1",
"supertest": "1.1.0" "supertest": "4.0.2"
}, },
"engines": { "engines": {
"node": ">= 0.8.0" "node": ">= 0.8.0"
@ -84,8 +84,8 @@
"scripts": { "scripts": {
"lint": "eslint --plugin markdown --ext js,md .", "lint": "eslint --plugin markdown --ext js,md .",
"test": "mocha --check-leaks --reporter spec --bail", "test": "mocha --check-leaks --reporter spec --bail",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --reporter dot", "test-ci": "nyc --reporter=text npm test",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --reporter spec" "test-cov": "nyc --reporter=html --reporter=text npm test"
}, },
"version": "1.9.1" "version": "1.10.0"
} }

48
node_modules/ms/index.js generated vendored

@ -6,6 +6,7 @@ var s = 1000;
var m = s * 60; var m = s * 60;
var h = m * 60; var h = m * 60;
var d = h * 24; var d = h * 24;
var w = d * 7;
var y = d * 365.25; var y = d * 365.25;
/** /**
@ -27,7 +28,7 @@ module.exports = function(val, options) {
var type = typeof val; var type = typeof val;
if (type === 'string' && val.length > 0) { if (type === 'string' && val.length > 0) {
return parse(val); return parse(val);
} else if (type === 'number' && isNaN(val) === false) { } else if (type === 'number' && isFinite(val)) {
return options.long ? fmtLong(val) : fmtShort(val); return options.long ? fmtLong(val) : fmtShort(val);
} }
throw new Error( throw new Error(
@ -49,7 +50,7 @@ function parse(str) {
if (str.length > 100) { if (str.length > 100) {
return; return;
} }
var match = /^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec( var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(
str str
); );
if (!match) { if (!match) {
@ -64,6 +65,10 @@ function parse(str) {
case 'yr': case 'yr':
case 'y': case 'y':
return n * y; return n * y;
case 'weeks':
case 'week':
case 'w':
return n * w;
case 'days': case 'days':
case 'day': case 'day':
case 'd': case 'd':
@ -106,16 +111,17 @@ function parse(str) {
*/ */
function fmtShort(ms) { function fmtShort(ms) {
if (ms >= d) { var msAbs = Math.abs(ms);
if (msAbs >= d) {
return Math.round(ms / d) + 'd'; return Math.round(ms / d) + 'd';
} }
if (ms >= h) { if (msAbs >= h) {
return Math.round(ms / h) + 'h'; return Math.round(ms / h) + 'h';
} }
if (ms >= m) { if (msAbs >= m) {
return Math.round(ms / m) + 'm'; return Math.round(ms / m) + 'm';
} }
if (ms >= s) { if (msAbs >= s) {
return Math.round(ms / s) + 's'; return Math.round(ms / s) + 's';
} }
return ms + 'ms'; return ms + 'ms';
@ -130,23 +136,27 @@ function fmtShort(ms) {
*/ */
function fmtLong(ms) { function fmtLong(ms) {
return plural(ms, d, 'day') || var msAbs = Math.abs(ms);
plural(ms, h, 'hour') || if (msAbs >= d) {
plural(ms, m, 'minute') || return plural(ms, msAbs, d, 'day');
plural(ms, s, 'second') || }
ms + ' ms'; if (msAbs >= h) {
return plural(ms, msAbs, h, 'hour');
}
if (msAbs >= m) {
return plural(ms, msAbs, m, 'minute');
}
if (msAbs >= s) {
return plural(ms, msAbs, s, 'second');
}
return ms + ' ms';
} }
/** /**
* Pluralization helper. * Pluralization helper.
*/ */
function plural(ms, n, name) { function plural(ms, msAbs, n, name) {
if (ms < n) { var isPlural = msAbs >= n * 1.5;
return; return Math.round(ms / n) + ' ' + name + (isPlural ? 's' : '');
}
if (ms < n * 1.5) {
return Math.floor(ms / n) + ' ' + name;
}
return Math.ceil(ms / n) + ' ' + name + 's';
} }

36
node_modules/ms/package.json generated vendored

@ -1,40 +1,40 @@
{ {
"_from": "ms@2.0.0", "_from": "ms@^2.1.1",
"_id": "ms@2.0.0", "_id": "ms@2.1.2",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", "_integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==",
"_location": "/ms", "_location": "/ms",
"_phantomChildren": {}, "_phantomChildren": {},
"_requested": { "_requested": {
"type": "version", "type": "range",
"registry": true, "registry": true,
"raw": "ms@2.0.0", "raw": "ms@^2.1.1",
"name": "ms", "name": "ms",
"escapedName": "ms", "escapedName": "ms",
"rawSpec": "2.0.0", "rawSpec": "^2.1.1",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "2.0.0" "fetchSpec": "^2.1.1"
}, },
"_requiredBy": [ "_requiredBy": [
"/debug", "/debug",
"/send" "/nodemon/debug"
], ],
"_resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", "_resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
"_shasum": "5608aeadfc00be6c2901df5f9861788de0d597c8", "_shasum": "d09d1f357b443f493382a8eb3ccd183872ae6009",
"_spec": "ms@2.0.0", "_spec": "ms@^2.1.1",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/debug", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/debug",
"bugs": { "bugs": {
"url": "https://github.com/zeit/ms/issues" "url": "https://github.com/zeit/ms/issues"
}, },
"bundleDependencies": false, "bundleDependencies": false,
"deprecated": false, "deprecated": false,
"description": "Tiny milisecond conversion utility", "description": "Tiny millisecond conversion utility",
"devDependencies": { "devDependencies": {
"eslint": "3.19.0", "eslint": "4.12.1",
"expect.js": "0.3.1", "expect.js": "0.3.1",
"husky": "0.13.3", "husky": "0.14.3",
"lint-staged": "3.4.1", "lint-staged": "5.0.0",
"mocha": "3.4.1" "mocha": "4.0.1"
}, },
"eslintConfig": { "eslintConfig": {
"extends": "eslint:recommended", "extends": "eslint:recommended",
@ -66,5 +66,5 @@
"precommit": "lint-staged", "precommit": "lint-staged",
"test": "mocha tests.js" "test": "mocha tests.js"
}, },
"version": "2.0.0" "version": "2.1.2"
} }

27
node_modules/ms/readme.md generated vendored

@ -1,7 +1,7 @@
# ms # ms
[![Build Status](https://travis-ci.org/zeit/ms.svg?branch=master)](https://travis-ci.org/zeit/ms) [![Build Status](https://travis-ci.org/zeit/ms.svg?branch=master)](https://travis-ci.org/zeit/ms)
[![Slack Channel](http://zeit-slackin.now.sh/badge.svg)](https://zeit.chat/) [![Join the community on Spectrum](https://withspectrum.github.io/badge/badge.svg)](https://spectrum.chat/zeit)
Use this package to easily convert various time formats to milliseconds. Use this package to easily convert various time formats to milliseconds.
@ -17,35 +17,44 @@ ms('1m') // 60000
ms('5s') // 5000 ms('5s') // 5000
ms('1y') // 31557600000 ms('1y') // 31557600000
ms('100') // 100 ms('100') // 100
ms('-3 days') // -259200000
ms('-1h') // -3600000
ms('-200') // -200
``` ```
### Convert from milliseconds ### Convert from Milliseconds
```js ```js
ms(60000) // "1m" ms(60000) // "1m"
ms(2 * 60000) // "2m" ms(2 * 60000) // "2m"
ms(-3 * 60000) // "-3m"
ms(ms('10 hours')) // "10h" ms(ms('10 hours')) // "10h"
``` ```
### Time format written-out ### Time Format Written-Out
```js ```js
ms(60000, { long: true }) // "1 minute" ms(60000, { long: true }) // "1 minute"
ms(2 * 60000, { long: true }) // "2 minutes" ms(2 * 60000, { long: true }) // "2 minutes"
ms(-3 * 60000, { long: true }) // "-3 minutes"
ms(ms('10 hours'), { long: true }) // "10 hours" ms(ms('10 hours'), { long: true }) // "10 hours"
``` ```
## Features ## Features
- Works both in [node](https://nodejs.org) and in the browser. - Works both in [Node.js](https://nodejs.org) and in the browser
- If a number is supplied to `ms`, a string with a unit is returned. - If a number is supplied to `ms`, a string with a unit is returned
- If a string that contains the number is supplied, it returns it as a number (e.g.: it returns `100` for `'100'`). - If a string that contains the number is supplied, it returns it as a number (e.g.: it returns `100` for `'100'`)
- If you pass a string with a number and a valid unit, the number of equivalent ms is returned. - If you pass a string with a number and a valid unit, the number of equivalent milliseconds is returned
## Caught a bug? ## Related Packages
- [ms.macro](https://github.com/knpwrs/ms.macro) - Run `ms` as a macro at build-time.
## Caught a Bug?
1. [Fork](https://help.github.com/articles/fork-a-repo/) this repository to your own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local device 1. [Fork](https://help.github.com/articles/fork-a-repo/) this repository to your own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local device
2. Link the package to the global module directory: `npm link` 2. Link the package to the global module directory: `npm link`
3. Within the module you want to test your local development instance of ms, just link it to the dependencies: `npm link ms`. Instead of the default one from npm, node will now use your clone of ms! 3. Within the module you want to test your local development instance of ms, just link it to the dependencies: `npm link ms`. Instead of the default one from npm, Node.js will now use your clone of ms!
As always, you can run the tests using: `npm test` As always, you can run the tests using: `npm test`

2
node_modules/negotiator/package.json generated vendored

@ -21,7 +21,7 @@
"_resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz", "_resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz",
"_shasum": "feacf7ccf525a77ae9634436a64883ffeca346fb", "_shasum": "feacf7ccf525a77ae9634436a64883ffeca346fb",
"_spec": "negotiator@0.6.2", "_spec": "negotiator@0.6.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/accepts", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/accepts",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/negotiator/issues" "url": "https://github.com/jshttp/negotiator/issues"
}, },

2
node_modules/on-finished/package.json generated vendored

@ -25,7 +25,7 @@
"_resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", "_resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz",
"_shasum": "20f1336481b083cd75337992a16971aa2d906947", "_shasum": "20f1336481b083cd75337992a16971aa2d906947",
"_spec": "on-finished@~2.3.0", "_spec": "on-finished@~2.3.0",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"bugs": { "bugs": {
"url": "https://github.com/jshttp/on-finished/issues" "url": "https://github.com/jshttp/on-finished/issues"
}, },

12
node_modules/on-headers/package.json generated vendored

@ -1,5 +1,5 @@
{ {
"_from": "on-headers@~1.0.1", "_from": "on-headers@~1.0.2",
"_id": "on-headers@1.0.2", "_id": "on-headers@1.0.2",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-pZAE+FJLoyITytdqK0U5s+FIpjN0JP3OzFi/u8Rx+EV5/W+JTWGXG8xFzevE7AjBfDqHv/8vL8qQsIhHnqRkrA==", "_integrity": "sha512-pZAE+FJLoyITytdqK0U5s+FIpjN0JP3OzFi/u8Rx+EV5/W+JTWGXG8xFzevE7AjBfDqHv/8vL8qQsIhHnqRkrA==",
@ -8,20 +8,20 @@
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "on-headers@~1.0.1", "raw": "on-headers@~1.0.2",
"name": "on-headers", "name": "on-headers",
"escapedName": "on-headers", "escapedName": "on-headers",
"rawSpec": "~1.0.1", "rawSpec": "~1.0.2",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~1.0.1" "fetchSpec": "~1.0.2"
}, },
"_requiredBy": [ "_requiredBy": [
"/morgan" "/morgan"
], ],
"_resolved": "https://registry.npmjs.org/on-headers/-/on-headers-1.0.2.tgz", "_resolved": "https://registry.npmjs.org/on-headers/-/on-headers-1.0.2.tgz",
"_shasum": "772b0ae6aaa525c399e489adfad90c403eb3c28f", "_shasum": "772b0ae6aaa525c399e489adfad90c403eb3c28f",
"_spec": "on-headers@~1.0.1", "_spec": "on-headers@~1.0.2",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/morgan", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/morgan",
"author": { "author": {
"name": "Douglas Christopher Wilson", "name": "Douglas Christopher Wilson",
"email": "doug@somethingdoug.com" "email": "doug@somethingdoug.com"

12
node_modules/parseurl/package.json generated vendored

@ -1,5 +1,5 @@
{ {
"_from": "parseurl@~1.3.2", "_from": "parseurl@~1.3.3",
"_id": "parseurl@1.3.3", "_id": "parseurl@1.3.3",
"_inBundle": false, "_inBundle": false,
"_integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", "_integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==",
@ -8,12 +8,12 @@
"_requested": { "_requested": {
"type": "range", "type": "range",
"registry": true, "registry": true,
"raw": "parseurl@~1.3.2", "raw": "parseurl@~1.3.3",
"name": "parseurl", "name": "parseurl",
"escapedName": "parseurl", "escapedName": "parseurl",
"rawSpec": "~1.3.2", "rawSpec": "~1.3.3",
"saveSpec": null, "saveSpec": null,
"fetchSpec": "~1.3.2" "fetchSpec": "~1.3.3"
}, },
"_requiredBy": [ "_requiredBy": [
"/express", "/express",
@ -22,8 +22,8 @@
], ],
"_resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", "_resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz",
"_shasum": "9da19e7bee8d12dff0513ed5b76957793bc2e8d4", "_shasum": "9da19e7bee8d12dff0513ed5b76957793bc2e8d4",
"_spec": "parseurl@~1.3.2", "_spec": "parseurl@~1.3.3",
"_where": "/home/f2256342/forge/es6-nodejs/node_modules/express", "_where": "/home/yutsuo/forge/nodejs/es6-express/node_modules/express",
"bugs": { "bugs": {
"url": "https://github.com/pillarjs/parseurl/issues" "url": "https://github.com/pillarjs/parseurl/issues"
}, },

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save