bare-http1 3.2.0 → 3.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -7,6 +7,8 @@ exports.ServerConnection = require('./lib/server-connection')
7
7
 
8
8
  exports.constants = require('./lib/constants')
9
9
 
10
+ exports.STATUS_CODES = exports.constants.status // For Node.js compatibility
11
+
10
12
  exports.createServer = function createServer (opts, onrequest) {
11
13
  return new Server(opts, onrequest)
12
14
  }
package/lib/constants.js CHANGED
@@ -3,17 +3,20 @@ module.exports = {
3
3
  100: 'Continue',
4
4
  101: 'Switching Protocols',
5
5
  102: 'Processing',
6
+ 103: 'Early Hints',
6
7
  200: 'OK',
7
8
  201: 'Created',
8
9
  202: 'Accepted',
9
- 203: 'Non Authoritative Information',
10
+ 203: 'Non-Authoritative Information',
10
11
  204: 'No Content',
11
12
  205: 'Reset Content',
12
13
  206: 'Partial Content',
13
14
  207: 'Multi-Status',
15
+ 208: 'Already Reported',
16
+ 226: 'IM Used',
14
17
  300: 'Multiple Choices',
15
18
  301: 'Moved Permanently',
16
- 302: 'Moved Temporarily',
19
+ 302: 'Found',
17
20
  303: 'See Other',
18
21
  304: 'Not Modified',
19
22
  305: 'Use Proxy',
@@ -32,18 +35,18 @@ module.exports = {
32
35
  410: 'Gone',
33
36
  411: 'Length Required',
34
37
  412: 'Precondition Failed',
35
- 413: 'Request Entity Too Large',
36
- 414: 'Request-URI Too Long',
38
+ 413: 'Payload Too Large',
39
+ 414: 'URI Too Long',
37
40
  415: 'Unsupported Media Type',
38
- 416: 'Requested Range Not Satisfiable',
41
+ 416: 'Range Not Satisfiable',
39
42
  417: 'Expectation Failed',
40
- 418: 'I\'m a teapot',
41
- 419: 'Insufficient Space on Resource',
42
- 420: 'Method Failure',
43
+ 418: "I'm a Teapot",
43
44
  421: 'Misdirected Request',
44
45
  422: 'Unprocessable Entity',
45
46
  423: 'Locked',
46
47
  424: 'Failed Dependency',
48
+ 425: 'Too Early',
49
+ 426: 'Upgrade Required',
47
50
  428: 'Precondition Required',
48
51
  429: 'Too Many Requests',
49
52
  431: 'Request Header Fields Too Large',
@@ -54,7 +57,11 @@ module.exports = {
54
57
  503: 'Service Unavailable',
55
58
  504: 'Gateway Timeout',
56
59
  505: 'HTTP Version Not Supported',
60
+ 506: 'Variant Also Negotiates',
57
61
  507: 'Insufficient Storage',
62
+ 508: 'Loop Detected',
63
+ 509: 'Bandwidth Limit Exceeded',
64
+ 510: 'Not Extended',
58
65
  511: 'Network Authentication Required'
59
66
  }
60
67
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bare-http1",
3
- "version": "3.2.0",
3
+ "version": "3.2.1",
4
4
  "description": "Native HTTP/1 library for JavaScript",
5
5
  "exports": {
6
6
  ".": "./index.js",