lnlink-server 1.0.7 → 1.0.9
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/dist/app.js +169 -169
- package/dist/build-info.json +2 -1
- package/dist/index.js +121 -55
- package/dist/index.js.map +3 -3
- package/dist/package.json +2 -1
- package/dist/public/css/initOwner.css +69 -0
- package/dist/public/js/init.js +376 -378
- package/package.json +2 -1
- package/dist/node_modules/debug/.coveralls.yml +0 -1
- package/dist/node_modules/debug/.eslintrc +0 -11
- package/dist/node_modules/debug/.travis.yml +0 -14
- package/dist/node_modules/debug/CHANGELOG.md +0 -362
- package/dist/node_modules/debug/LICENSE +0 -19
- package/dist/node_modules/debug/Makefile +0 -50
- package/dist/node_modules/debug/README.md +0 -312
- package/dist/node_modules/debug/component.json +0 -19
- package/dist/node_modules/debug/karma.conf.js +0 -70
- package/dist/node_modules/debug/node.js +0 -1
- package/dist/node_modules/debug/package.json +0 -49
- package/dist/node_modules/debug/src/browser.js +0 -185
- package/dist/node_modules/debug/src/debug.js +0 -202
- package/dist/node_modules/debug/src/index.js +0 -10
- package/dist/node_modules/debug/src/inspector-log.js +0 -15
- package/dist/node_modules/debug/src/node.js +0 -248
- package/dist/node_modules/depd/History.md +0 -96
- package/dist/node_modules/depd/LICENSE +0 -22
- package/dist/node_modules/depd/Readme.md +0 -280
- package/dist/node_modules/depd/index.js +0 -522
- package/dist/node_modules/depd/lib/browser/index.js +0 -77
- package/dist/node_modules/depd/lib/compat/callsite-tostring.js +0 -103
- package/dist/node_modules/depd/lib/compat/event-listener-count.js +0 -22
- package/dist/node_modules/depd/lib/compat/index.js +0 -79
- package/dist/node_modules/depd/package.json +0 -41
- package/dist/node_modules/http-errors/HISTORY.md +0 -132
- package/dist/node_modules/http-errors/LICENSE +0 -23
- package/dist/node_modules/http-errors/README.md +0 -135
- package/dist/node_modules/http-errors/index.js +0 -260
- package/dist/node_modules/http-errors/package.json +0 -48
- package/dist/node_modules/inherits/LICENSE +0 -16
- package/dist/node_modules/inherits/README.md +0 -42
- package/dist/node_modules/inherits/inherits.js +0 -7
- package/dist/node_modules/inherits/inherits_browser.js +0 -23
- package/dist/node_modules/inherits/package.json +0 -29
- package/dist/node_modules/ms/index.js +0 -152
- package/dist/node_modules/ms/license.md +0 -21
- package/dist/node_modules/ms/package.json +0 -37
- package/dist/node_modules/ms/readme.md +0 -51
- package/dist/node_modules/setprototypeof/LICENSE +0 -13
- package/dist/node_modules/setprototypeof/README.md +0 -26
- package/dist/node_modules/setprototypeof/index.d.ts +0 -2
- package/dist/node_modules/setprototypeof/index.js +0 -15
- package/dist/node_modules/setprototypeof/package.json +0 -25
- package/dist/node_modules/statuses/HISTORY.md +0 -65
- package/dist/node_modules/statuses/LICENSE +0 -23
- package/dist/node_modules/statuses/README.md +0 -127
- package/dist/node_modules/statuses/codes.json +0 -66
- package/dist/node_modules/statuses/index.js +0 -113
- package/dist/node_modules/statuses/package.json +0 -48
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "http-errors",
|
|
3
|
-
"description": "Create HTTP error objects",
|
|
4
|
-
"version": "1.6.3",
|
|
5
|
-
"author": "Jonathan Ong <me@jongleberry.com> (http://jongleberry.com)",
|
|
6
|
-
"contributors": [
|
|
7
|
-
"Alan Plum <me@pluma.io>",
|
|
8
|
-
"Douglas Christopher Wilson <doug@somethingdoug.com>"
|
|
9
|
-
],
|
|
10
|
-
"license": "MIT",
|
|
11
|
-
"repository": "jshttp/http-errors",
|
|
12
|
-
"dependencies": {
|
|
13
|
-
"depd": "~1.1.2",
|
|
14
|
-
"inherits": "2.0.3",
|
|
15
|
-
"setprototypeof": "1.1.0",
|
|
16
|
-
"statuses": ">= 1.4.0 < 2"
|
|
17
|
-
},
|
|
18
|
-
"devDependencies": {
|
|
19
|
-
"eslint": "4.18.1",
|
|
20
|
-
"eslint-config-standard": "11.0.0",
|
|
21
|
-
"eslint-plugin-import": "2.9.0",
|
|
22
|
-
"eslint-plugin-markdown": "1.0.0-beta.6",
|
|
23
|
-
"eslint-plugin-node": "6.0.1",
|
|
24
|
-
"eslint-plugin-promise": "3.6.0",
|
|
25
|
-
"eslint-plugin-standard": "3.0.1",
|
|
26
|
-
"istanbul": "0.4.5",
|
|
27
|
-
"mocha": "1.21.5"
|
|
28
|
-
},
|
|
29
|
-
"engines": {
|
|
30
|
-
"node": ">= 0.6"
|
|
31
|
-
},
|
|
32
|
-
"scripts": {
|
|
33
|
-
"lint": "eslint --plugin markdown --ext js,md .",
|
|
34
|
-
"test": "mocha --reporter spec --bail",
|
|
35
|
-
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot",
|
|
36
|
-
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot"
|
|
37
|
-
},
|
|
38
|
-
"keywords": [
|
|
39
|
-
"http",
|
|
40
|
-
"error"
|
|
41
|
-
],
|
|
42
|
-
"files": [
|
|
43
|
-
"index.js",
|
|
44
|
-
"HISTORY.md",
|
|
45
|
-
"LICENSE",
|
|
46
|
-
"README.md"
|
|
47
|
-
]
|
|
48
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
The ISC License
|
|
2
|
-
|
|
3
|
-
Copyright (c) Isaac Z. Schlueter
|
|
4
|
-
|
|
5
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
-
purpose with or without fee is hereby granted, provided that the above
|
|
7
|
-
copyright notice and this permission notice appear in all copies.
|
|
8
|
-
|
|
9
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
10
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
|
11
|
-
FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
12
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
13
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
14
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
15
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
16
|
-
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
Browser-friendly inheritance fully compatible with standard node.js
|
|
2
|
-
[inherits](http://nodejs.org/api/util.html#util_util_inherits_constructor_superconstructor).
|
|
3
|
-
|
|
4
|
-
This package exports standard `inherits` from node.js `util` module in
|
|
5
|
-
node environment, but also provides alternative browser-friendly
|
|
6
|
-
implementation through [browser
|
|
7
|
-
field](https://gist.github.com/shtylman/4339901). Alternative
|
|
8
|
-
implementation is a literal copy of standard one located in standalone
|
|
9
|
-
module to avoid requiring of `util`. It also has a shim for old
|
|
10
|
-
browsers with no `Object.create` support.
|
|
11
|
-
|
|
12
|
-
While keeping you sure you are using standard `inherits`
|
|
13
|
-
implementation in node.js environment, it allows bundlers such as
|
|
14
|
-
[browserify](https://github.com/substack/node-browserify) to not
|
|
15
|
-
include full `util` package to your client code if all you need is
|
|
16
|
-
just `inherits` function. It worth, because browser shim for `util`
|
|
17
|
-
package is large and `inherits` is often the single function you need
|
|
18
|
-
from it.
|
|
19
|
-
|
|
20
|
-
It's recommended to use this package instead of
|
|
21
|
-
`require('util').inherits` for any code that has chances to be used
|
|
22
|
-
not only in node.js but in browser too.
|
|
23
|
-
|
|
24
|
-
## usage
|
|
25
|
-
|
|
26
|
-
```js
|
|
27
|
-
var inherits = require('inherits');
|
|
28
|
-
// then use exactly as the standard one
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
## note on version ~1.0
|
|
32
|
-
|
|
33
|
-
Version ~1.0 had completely different motivation and is not compatible
|
|
34
|
-
neither with 2.0 nor with standard node.js `inherits`.
|
|
35
|
-
|
|
36
|
-
If you are using version ~1.0 and planning to switch to ~2.0, be
|
|
37
|
-
careful:
|
|
38
|
-
|
|
39
|
-
* new version uses `super_` instead of `super` for referencing
|
|
40
|
-
superclass
|
|
41
|
-
* new version overwrites current prototype while old one preserves any
|
|
42
|
-
existing fields on it
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
if (typeof Object.create === 'function') {
|
|
2
|
-
// implementation from standard node.js 'util' module
|
|
3
|
-
module.exports = function inherits(ctor, superCtor) {
|
|
4
|
-
ctor.super_ = superCtor
|
|
5
|
-
ctor.prototype = Object.create(superCtor.prototype, {
|
|
6
|
-
constructor: {
|
|
7
|
-
value: ctor,
|
|
8
|
-
enumerable: false,
|
|
9
|
-
writable: true,
|
|
10
|
-
configurable: true
|
|
11
|
-
}
|
|
12
|
-
});
|
|
13
|
-
};
|
|
14
|
-
} else {
|
|
15
|
-
// old school shim for old browsers
|
|
16
|
-
module.exports = function inherits(ctor, superCtor) {
|
|
17
|
-
ctor.super_ = superCtor
|
|
18
|
-
var TempCtor = function () {}
|
|
19
|
-
TempCtor.prototype = superCtor.prototype
|
|
20
|
-
ctor.prototype = new TempCtor()
|
|
21
|
-
ctor.prototype.constructor = ctor
|
|
22
|
-
}
|
|
23
|
-
}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "inherits",
|
|
3
|
-
"description": "Browser-friendly inheritance fully compatible with standard node.js inherits()",
|
|
4
|
-
"version": "2.0.3",
|
|
5
|
-
"keywords": [
|
|
6
|
-
"inheritance",
|
|
7
|
-
"class",
|
|
8
|
-
"klass",
|
|
9
|
-
"oop",
|
|
10
|
-
"object-oriented",
|
|
11
|
-
"inherits",
|
|
12
|
-
"browser",
|
|
13
|
-
"browserify"
|
|
14
|
-
],
|
|
15
|
-
"main": "./inherits.js",
|
|
16
|
-
"browser": "./inherits_browser.js",
|
|
17
|
-
"repository": "git://github.com/isaacs/inherits",
|
|
18
|
-
"license": "ISC",
|
|
19
|
-
"scripts": {
|
|
20
|
-
"test": "node test"
|
|
21
|
-
},
|
|
22
|
-
"devDependencies": {
|
|
23
|
-
"tap": "^7.1.0"
|
|
24
|
-
},
|
|
25
|
-
"files": [
|
|
26
|
-
"inherits.js",
|
|
27
|
-
"inherits_browser.js"
|
|
28
|
-
]
|
|
29
|
-
}
|
|
@@ -1,152 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Helpers.
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
var s = 1000;
|
|
6
|
-
var m = s * 60;
|
|
7
|
-
var h = m * 60;
|
|
8
|
-
var d = h * 24;
|
|
9
|
-
var y = d * 365.25;
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Parse or format the given `val`.
|
|
13
|
-
*
|
|
14
|
-
* Options:
|
|
15
|
-
*
|
|
16
|
-
* - `long` verbose formatting [false]
|
|
17
|
-
*
|
|
18
|
-
* @param {String|Number} val
|
|
19
|
-
* @param {Object} [options]
|
|
20
|
-
* @throws {Error} throw an error if val is not a non-empty string or a number
|
|
21
|
-
* @return {String|Number}
|
|
22
|
-
* @api public
|
|
23
|
-
*/
|
|
24
|
-
|
|
25
|
-
module.exports = function(val, options) {
|
|
26
|
-
options = options || {};
|
|
27
|
-
var type = typeof val;
|
|
28
|
-
if (type === 'string' && val.length > 0) {
|
|
29
|
-
return parse(val);
|
|
30
|
-
} else if (type === 'number' && isNaN(val) === false) {
|
|
31
|
-
return options.long ? fmtLong(val) : fmtShort(val);
|
|
32
|
-
}
|
|
33
|
-
throw new Error(
|
|
34
|
-
'val is not a non-empty string or a valid number. val=' +
|
|
35
|
-
JSON.stringify(val)
|
|
36
|
-
);
|
|
37
|
-
};
|
|
38
|
-
|
|
39
|
-
/**
|
|
40
|
-
* Parse the given `str` and return milliseconds.
|
|
41
|
-
*
|
|
42
|
-
* @param {String} str
|
|
43
|
-
* @return {Number}
|
|
44
|
-
* @api private
|
|
45
|
-
*/
|
|
46
|
-
|
|
47
|
-
function parse(str) {
|
|
48
|
-
str = String(str);
|
|
49
|
-
if (str.length > 100) {
|
|
50
|
-
return;
|
|
51
|
-
}
|
|
52
|
-
var match = /^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(
|
|
53
|
-
str
|
|
54
|
-
);
|
|
55
|
-
if (!match) {
|
|
56
|
-
return;
|
|
57
|
-
}
|
|
58
|
-
var n = parseFloat(match[1]);
|
|
59
|
-
var type = (match[2] || 'ms').toLowerCase();
|
|
60
|
-
switch (type) {
|
|
61
|
-
case 'years':
|
|
62
|
-
case 'year':
|
|
63
|
-
case 'yrs':
|
|
64
|
-
case 'yr':
|
|
65
|
-
case 'y':
|
|
66
|
-
return n * y;
|
|
67
|
-
case 'days':
|
|
68
|
-
case 'day':
|
|
69
|
-
case 'd':
|
|
70
|
-
return n * d;
|
|
71
|
-
case 'hours':
|
|
72
|
-
case 'hour':
|
|
73
|
-
case 'hrs':
|
|
74
|
-
case 'hr':
|
|
75
|
-
case 'h':
|
|
76
|
-
return n * h;
|
|
77
|
-
case 'minutes':
|
|
78
|
-
case 'minute':
|
|
79
|
-
case 'mins':
|
|
80
|
-
case 'min':
|
|
81
|
-
case 'm':
|
|
82
|
-
return n * m;
|
|
83
|
-
case 'seconds':
|
|
84
|
-
case 'second':
|
|
85
|
-
case 'secs':
|
|
86
|
-
case 'sec':
|
|
87
|
-
case 's':
|
|
88
|
-
return n * s;
|
|
89
|
-
case 'milliseconds':
|
|
90
|
-
case 'millisecond':
|
|
91
|
-
case 'msecs':
|
|
92
|
-
case 'msec':
|
|
93
|
-
case 'ms':
|
|
94
|
-
return n;
|
|
95
|
-
default:
|
|
96
|
-
return undefined;
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
/**
|
|
101
|
-
* Short format for `ms`.
|
|
102
|
-
*
|
|
103
|
-
* @param {Number} ms
|
|
104
|
-
* @return {String}
|
|
105
|
-
* @api private
|
|
106
|
-
*/
|
|
107
|
-
|
|
108
|
-
function fmtShort(ms) {
|
|
109
|
-
if (ms >= d) {
|
|
110
|
-
return Math.round(ms / d) + 'd';
|
|
111
|
-
}
|
|
112
|
-
if (ms >= h) {
|
|
113
|
-
return Math.round(ms / h) + 'h';
|
|
114
|
-
}
|
|
115
|
-
if (ms >= m) {
|
|
116
|
-
return Math.round(ms / m) + 'm';
|
|
117
|
-
}
|
|
118
|
-
if (ms >= s) {
|
|
119
|
-
return Math.round(ms / s) + 's';
|
|
120
|
-
}
|
|
121
|
-
return ms + 'ms';
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
/**
|
|
125
|
-
* Long format for `ms`.
|
|
126
|
-
*
|
|
127
|
-
* @param {Number} ms
|
|
128
|
-
* @return {String}
|
|
129
|
-
* @api private
|
|
130
|
-
*/
|
|
131
|
-
|
|
132
|
-
function fmtLong(ms) {
|
|
133
|
-
return plural(ms, d, 'day') ||
|
|
134
|
-
plural(ms, h, 'hour') ||
|
|
135
|
-
plural(ms, m, 'minute') ||
|
|
136
|
-
plural(ms, s, 'second') ||
|
|
137
|
-
ms + ' ms';
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
/**
|
|
141
|
-
* Pluralization helper.
|
|
142
|
-
*/
|
|
143
|
-
|
|
144
|
-
function plural(ms, n, name) {
|
|
145
|
-
if (ms < n) {
|
|
146
|
-
return;
|
|
147
|
-
}
|
|
148
|
-
if (ms < n * 1.5) {
|
|
149
|
-
return Math.floor(ms / n) + ' ' + name;
|
|
150
|
-
}
|
|
151
|
-
return Math.ceil(ms / n) + ' ' + name + 's';
|
|
152
|
-
}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
The MIT License (MIT)
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2016 Zeit, Inc.
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "ms",
|
|
3
|
-
"version": "2.0.0",
|
|
4
|
-
"description": "Tiny milisecond conversion utility",
|
|
5
|
-
"repository": "zeit/ms",
|
|
6
|
-
"main": "./index",
|
|
7
|
-
"files": [
|
|
8
|
-
"index.js"
|
|
9
|
-
],
|
|
10
|
-
"scripts": {
|
|
11
|
-
"precommit": "lint-staged",
|
|
12
|
-
"lint": "eslint lib/* bin/*",
|
|
13
|
-
"test": "mocha tests.js"
|
|
14
|
-
},
|
|
15
|
-
"eslintConfig": {
|
|
16
|
-
"extends": "eslint:recommended",
|
|
17
|
-
"env": {
|
|
18
|
-
"node": true,
|
|
19
|
-
"es6": true
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
"lint-staged": {
|
|
23
|
-
"*.js": [
|
|
24
|
-
"npm run lint",
|
|
25
|
-
"prettier --single-quote --write",
|
|
26
|
-
"git add"
|
|
27
|
-
]
|
|
28
|
-
},
|
|
29
|
-
"license": "MIT",
|
|
30
|
-
"devDependencies": {
|
|
31
|
-
"eslint": "3.19.0",
|
|
32
|
-
"expect.js": "0.3.1",
|
|
33
|
-
"husky": "0.13.3",
|
|
34
|
-
"lint-staged": "3.4.1",
|
|
35
|
-
"mocha": "3.4.1"
|
|
36
|
-
}
|
|
37
|
-
}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
# ms
|
|
2
|
-
|
|
3
|
-
[](https://travis-ci.org/zeit/ms)
|
|
4
|
-
[](https://zeit.chat/)
|
|
5
|
-
|
|
6
|
-
Use this package to easily convert various time formats to milliseconds.
|
|
7
|
-
|
|
8
|
-
## Examples
|
|
9
|
-
|
|
10
|
-
```js
|
|
11
|
-
ms('2 days') // 172800000
|
|
12
|
-
ms('1d') // 86400000
|
|
13
|
-
ms('10h') // 36000000
|
|
14
|
-
ms('2.5 hrs') // 9000000
|
|
15
|
-
ms('2h') // 7200000
|
|
16
|
-
ms('1m') // 60000
|
|
17
|
-
ms('5s') // 5000
|
|
18
|
-
ms('1y') // 31557600000
|
|
19
|
-
ms('100') // 100
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
### Convert from milliseconds
|
|
23
|
-
|
|
24
|
-
```js
|
|
25
|
-
ms(60000) // "1m"
|
|
26
|
-
ms(2 * 60000) // "2m"
|
|
27
|
-
ms(ms('10 hours')) // "10h"
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
### Time format written-out
|
|
31
|
-
|
|
32
|
-
```js
|
|
33
|
-
ms(60000, { long: true }) // "1 minute"
|
|
34
|
-
ms(2 * 60000, { long: true }) // "2 minutes"
|
|
35
|
-
ms(ms('10 hours'), { long: true }) // "10 hours"
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
## Features
|
|
39
|
-
|
|
40
|
-
- Works both in [node](https://nodejs.org) and in the browser.
|
|
41
|
-
- If a number is supplied to `ms`, a string with a unit is returned.
|
|
42
|
-
- If a string that contains the number is supplied, it returns it as a number (e.g.: it returns `100` for `'100'`).
|
|
43
|
-
- If you pass a string with a number and a valid unit, the number of equivalent ms is returned.
|
|
44
|
-
|
|
45
|
-
## Caught a bug?
|
|
46
|
-
|
|
47
|
-
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
|
|
48
|
-
2. Link the package to the global module directory: `npm link`
|
|
49
|
-
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!
|
|
50
|
-
|
|
51
|
-
As always, you can run the tests using: `npm test`
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
Copyright (c) 2015, Wes Todd
|
|
2
|
-
|
|
3
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
4
|
-
purpose with or without fee is hereby granted, provided that the above
|
|
5
|
-
copyright notice and this permission notice appear in all copies.
|
|
6
|
-
|
|
7
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
8
|
-
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
9
|
-
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
|
|
10
|
-
SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
11
|
-
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
|
|
12
|
-
OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
|
|
13
|
-
CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
# Polyfill for `Object.setPrototypeOf`
|
|
2
|
-
|
|
3
|
-
A simple cross platform implementation to set the prototype of an instianted object. Supports all modern browsers and at least back to IE8.
|
|
4
|
-
|
|
5
|
-
## Usage:
|
|
6
|
-
|
|
7
|
-
```
|
|
8
|
-
$ npm install --save setprototypeof
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
```javascript
|
|
12
|
-
var setPrototypeOf = require('setprototypeof');
|
|
13
|
-
|
|
14
|
-
var obj = {};
|
|
15
|
-
setPrototypeOf(obj, {
|
|
16
|
-
foo: function() {
|
|
17
|
-
return 'bar';
|
|
18
|
-
}
|
|
19
|
-
});
|
|
20
|
-
obj.foo(); // bar
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
TypeScript is also supported:
|
|
24
|
-
```typescript
|
|
25
|
-
import setPrototypeOf = require('setprototypeof');
|
|
26
|
-
```
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
module.exports = Object.setPrototypeOf || ({__proto__:[]} instanceof Array ? setProtoOf : mixinProperties);
|
|
2
|
-
|
|
3
|
-
function setProtoOf(obj, proto) {
|
|
4
|
-
obj.__proto__ = proto;
|
|
5
|
-
return obj;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
function mixinProperties(obj, proto) {
|
|
9
|
-
for (var prop in proto) {
|
|
10
|
-
if (!obj.hasOwnProperty(prop)) {
|
|
11
|
-
obj[prop] = proto[prop];
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
return obj;
|
|
15
|
-
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "setprototypeof",
|
|
3
|
-
"version": "1.1.0",
|
|
4
|
-
"description": "A small polyfill for Object.setprototypeof",
|
|
5
|
-
"main": "index.js",
|
|
6
|
-
"typings": "index.d.ts",
|
|
7
|
-
"scripts": {
|
|
8
|
-
"test": "echo \"Error: no test specified\" && exit 1"
|
|
9
|
-
},
|
|
10
|
-
"repository": {
|
|
11
|
-
"type": "git",
|
|
12
|
-
"url": "https://github.com/wesleytodd/setprototypeof.git"
|
|
13
|
-
},
|
|
14
|
-
"keywords": [
|
|
15
|
-
"polyfill",
|
|
16
|
-
"object",
|
|
17
|
-
"setprototypeof"
|
|
18
|
-
],
|
|
19
|
-
"author": "Wes Todd",
|
|
20
|
-
"license": "ISC",
|
|
21
|
-
"bugs": {
|
|
22
|
-
"url": "https://github.com/wesleytodd/setprototypeof/issues"
|
|
23
|
-
},
|
|
24
|
-
"homepage": "https://github.com/wesleytodd/setprototypeof"
|
|
25
|
-
}
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
1.5.0 / 2018-03-27
|
|
2
|
-
==================
|
|
3
|
-
|
|
4
|
-
* Add `103 Early Hints`
|
|
5
|
-
|
|
6
|
-
1.4.0 / 2017-10-20
|
|
7
|
-
==================
|
|
8
|
-
|
|
9
|
-
* Add `STATUS_CODES` export
|
|
10
|
-
|
|
11
|
-
1.3.1 / 2016-11-11
|
|
12
|
-
==================
|
|
13
|
-
|
|
14
|
-
* Fix return type in JSDoc
|
|
15
|
-
|
|
16
|
-
1.3.0 / 2016-05-17
|
|
17
|
-
==================
|
|
18
|
-
|
|
19
|
-
* Add `421 Misdirected Request`
|
|
20
|
-
* perf: enable strict mode
|
|
21
|
-
|
|
22
|
-
1.2.1 / 2015-02-01
|
|
23
|
-
==================
|
|
24
|
-
|
|
25
|
-
* Fix message for status 451
|
|
26
|
-
- `451 Unavailable For Legal Reasons`
|
|
27
|
-
|
|
28
|
-
1.2.0 / 2014-09-28
|
|
29
|
-
==================
|
|
30
|
-
|
|
31
|
-
* Add `208 Already Repored`
|
|
32
|
-
* Add `226 IM Used`
|
|
33
|
-
* Add `306 (Unused)`
|
|
34
|
-
* Add `415 Unable For Legal Reasons`
|
|
35
|
-
* Add `508 Loop Detected`
|
|
36
|
-
|
|
37
|
-
1.1.1 / 2014-09-24
|
|
38
|
-
==================
|
|
39
|
-
|
|
40
|
-
* Add missing 308 to `codes.json`
|
|
41
|
-
|
|
42
|
-
1.1.0 / 2014-09-21
|
|
43
|
-
==================
|
|
44
|
-
|
|
45
|
-
* Add `codes.json` for universal support
|
|
46
|
-
|
|
47
|
-
1.0.4 / 2014-08-20
|
|
48
|
-
==================
|
|
49
|
-
|
|
50
|
-
* Package cleanup
|
|
51
|
-
|
|
52
|
-
1.0.3 / 2014-06-08
|
|
53
|
-
==================
|
|
54
|
-
|
|
55
|
-
* Add 308 to `.redirect` category
|
|
56
|
-
|
|
57
|
-
1.0.2 / 2014-03-13
|
|
58
|
-
==================
|
|
59
|
-
|
|
60
|
-
* Add `.retry` category
|
|
61
|
-
|
|
62
|
-
1.0.1 / 2014-03-12
|
|
63
|
-
==================
|
|
64
|
-
|
|
65
|
-
* Initial release
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
The MIT License (MIT)
|
|
3
|
-
|
|
4
|
-
Copyright (c) 2014 Jonathan Ong <me@jongleberry.com>
|
|
5
|
-
Copyright (c) 2016 Douglas Christopher Wilson <doug@somethingdoug.com>
|
|
6
|
-
|
|
7
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
9
|
-
in the Software without restriction, including without limitation the rights
|
|
10
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
12
|
-
furnished to do so, subject to the following conditions:
|
|
13
|
-
|
|
14
|
-
The above copyright notice and this permission notice shall be included in
|
|
15
|
-
all copies or substantial portions of the Software.
|
|
16
|
-
|
|
17
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
23
|
-
THE SOFTWARE.
|