@contrast/agent 4.16.1 → 4.16.2
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/bin/VERSION +1 -1
- package/bin/linux/contrast-service +0 -0
- package/bin/mac/contrast-service +0 -0
- package/bin/windows/contrast-service.exe +0 -0
- package/lib/protect/rules/cmd-injection/cmdinjection-rule.js +1 -1
- package/node_modules/async/CHANGELOG.md +13 -0
- package/node_modules/async/all.js +74 -9
- package/node_modules/async/allLimit.js +3 -3
- package/node_modules/async/allSeries.js +3 -3
- package/node_modules/async/any.js +75 -9
- package/node_modules/async/anyLimit.js +3 -3
- package/node_modules/async/anySeries.js +3 -3
- package/node_modules/async/applyEach.js +2 -2
- package/node_modules/async/applyEachSeries.js +2 -2
- package/node_modules/async/asyncify.js +3 -3
- package/node_modules/async/auto.js +81 -15
- package/node_modules/async/autoInject.js +30 -4
- package/node_modules/async/cargo.js +1 -1
- package/node_modules/async/cargoQueue.js +1 -1
- package/node_modules/async/compose.js +1 -1
- package/node_modules/async/concat.js +72 -4
- package/node_modules/async/concatLimit.js +3 -3
- package/node_modules/async/concatSeries.js +2 -2
- package/node_modules/async/detect.js +43 -8
- package/node_modules/async/detectLimit.js +3 -3
- package/node_modules/async/detectSeries.js +3 -3
- package/node_modules/async/dir.js +1 -1
- package/node_modules/async/dist/async.js +1379 -168
- package/node_modules/async/dist/async.min.js +1 -1
- package/node_modules/async/dist/async.mjs +1372 -161
- package/node_modules/async/doDuring.js +3 -3
- package/node_modules/async/doUntil.js +2 -2
- package/node_modules/async/doWhilst.js +3 -3
- package/node_modules/async/during.js +3 -3
- package/node_modules/async/each.js +69 -28
- package/node_modules/async/eachLimit.js +4 -4
- package/node_modules/async/eachOf.js +85 -16
- package/node_modules/async/eachOfLimit.js +3 -3
- package/node_modules/async/eachOfSeries.js +2 -2
- package/node_modules/async/eachSeries.js +2 -2
- package/node_modules/async/ensureAsync.js +2 -2
- package/node_modules/async/every.js +74 -9
- package/node_modules/async/everyLimit.js +3 -3
- package/node_modules/async/everySeries.js +3 -3
- package/node_modules/async/filter.js +49 -9
- package/node_modules/async/filterLimit.js +3 -3
- package/node_modules/async/filterSeries.js +3 -3
- package/node_modules/async/find.js +43 -8
- package/node_modules/async/findLimit.js +3 -3
- package/node_modules/async/findSeries.js +3 -3
- package/node_modules/async/flatMap.js +72 -4
- package/node_modules/async/flatMapLimit.js +3 -3
- package/node_modules/async/flatMapSeries.js +2 -2
- package/node_modules/async/foldl.js +87 -11
- package/node_modules/async/foldr.js +2 -2
- package/node_modules/async/forEach.js +69 -28
- package/node_modules/async/forEachLimit.js +4 -4
- package/node_modules/async/forEachOf.js +85 -16
- package/node_modules/async/forEachOfLimit.js +3 -3
- package/node_modules/async/forEachOfSeries.js +2 -2
- package/node_modules/async/forEachSeries.js +2 -2
- package/node_modules/async/forever.js +4 -4
- package/node_modules/async/groupBy.js +62 -8
- package/node_modules/async/groupByLimit.js +3 -3
- package/node_modules/async/groupBySeries.js +2 -2
- package/node_modules/async/inject.js +87 -11
- package/node_modules/async/internal/applyEach.js +2 -2
- package/node_modules/async/internal/asyncEachOfLimit.js +1 -1
- package/node_modules/async/internal/consoleFunc.js +5 -1
- package/node_modules/async/internal/createTester.js +2 -2
- package/node_modules/async/internal/eachOfLimit.js +6 -6
- package/node_modules/async/internal/filter.js +2 -2
- package/node_modules/async/internal/iterator.js +5 -2
- package/node_modules/async/internal/map.js +1 -1
- package/node_modules/async/internal/parallel.js +3 -3
- package/node_modules/async/internal/queue.js +4 -4
- package/node_modules/async/internal/reject.js +2 -2
- package/node_modules/async/internal/setImmediate.js +6 -2
- package/node_modules/async/internal/wrapAsync.js +1 -1
- package/node_modules/async/log.js +1 -1
- package/node_modules/async/map.js +86 -6
- package/node_modules/async/mapLimit.js +3 -3
- package/node_modules/async/mapSeries.js +3 -3
- package/node_modules/async/mapValues.js +102 -12
- package/node_modules/async/mapValuesLimit.js +4 -4
- package/node_modules/async/mapValuesSeries.js +1 -1
- package/node_modules/async/memoize.js +3 -3
- package/node_modules/async/nextTick.js +3 -3
- package/node_modules/async/package.json +4 -6
- package/node_modules/async/parallel.js +96 -7
- package/node_modules/async/parallelLimit.js +2 -2
- package/node_modules/async/priorityQueue.js +11 -4
- package/node_modules/async/queue.js +4 -4
- package/node_modules/async/race.js +3 -3
- package/node_modules/async/reduce.js +87 -11
- package/node_modules/async/reduceRight.js +2 -2
- package/node_modules/async/reflect.js +2 -2
- package/node_modules/async/reflectAll.js +1 -1
- package/node_modules/async/reject.js +44 -10
- package/node_modules/async/rejectLimit.js +3 -3
- package/node_modules/async/rejectSeries.js +3 -3
- package/node_modules/async/retry.js +2 -2
- package/node_modules/async/retryable.js +4 -4
- package/node_modules/async/select.js +49 -9
- package/node_modules/async/selectLimit.js +3 -3
- package/node_modules/async/selectSeries.js +3 -3
- package/node_modules/async/seq.js +4 -4
- package/node_modules/async/series.js +112 -12
- package/node_modules/async/setImmediate.js +1 -1
- package/node_modules/async/some.js +75 -9
- package/node_modules/async/someLimit.js +3 -3
- package/node_modules/async/someSeries.js +3 -3
- package/node_modules/async/sortBy.js +121 -19
- package/node_modules/async/timeout.js +2 -2
- package/node_modules/async/times.js +1 -1
- package/node_modules/async/timesLimit.js +3 -3
- package/node_modules/async/timesSeries.js +1 -1
- package/node_modules/async/transform.js +111 -19
- package/node_modules/async/tryEach.js +3 -3
- package/node_modules/async/until.js +3 -3
- package/node_modules/async/waterfall.js +4 -4
- package/node_modules/async/whilst.js +3 -3
- package/node_modules/async/wrapSync.js +3 -3
- package/package.json +1 -1
|
@@ -4,11 +4,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
|
|
7
|
-
var _concatLimit = require('./concatLimit');
|
|
7
|
+
var _concatLimit = require('./concatLimit.js');
|
|
8
8
|
|
|
9
9
|
var _concatLimit2 = _interopRequireDefault(_concatLimit);
|
|
10
10
|
|
|
11
|
-
var _awaitify = require('./internal/awaitify');
|
|
11
|
+
var _awaitify = require('./internal/awaitify.js');
|
|
12
12
|
|
|
13
13
|
var _awaitify2 = _interopRequireDefault(_awaitify);
|
|
14
14
|
|
|
@@ -36,9 +36,77 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
36
36
|
* @returns A Promise, if no callback is passed
|
|
37
37
|
* @example
|
|
38
38
|
*
|
|
39
|
-
*
|
|
40
|
-
*
|
|
39
|
+
* // dir1 is a directory that contains file1.txt, file2.txt
|
|
40
|
+
* // dir2 is a directory that contains file3.txt, file4.txt
|
|
41
|
+
* // dir3 is a directory that contains file5.txt
|
|
42
|
+
* // dir4 does not exist
|
|
43
|
+
*
|
|
44
|
+
* let directoryList = ['dir1','dir2','dir3'];
|
|
45
|
+
* let withMissingDirectoryList = ['dir1','dir2','dir3', 'dir4'];
|
|
46
|
+
*
|
|
47
|
+
* // Using callbacks
|
|
48
|
+
* async.concat(directoryList, fs.readdir, function(err, results) {
|
|
49
|
+
* if (err) {
|
|
50
|
+
* console.log(err);
|
|
51
|
+
* } else {
|
|
52
|
+
* console.log(results);
|
|
53
|
+
* // [ 'file1.txt', 'file2.txt', 'file3.txt', 'file4.txt', file5.txt ]
|
|
54
|
+
* }
|
|
55
|
+
* });
|
|
56
|
+
*
|
|
57
|
+
* // Error Handling
|
|
58
|
+
* async.concat(withMissingDirectoryList, fs.readdir, function(err, results) {
|
|
59
|
+
* if (err) {
|
|
60
|
+
* console.log(err);
|
|
61
|
+
* // [ Error: ENOENT: no such file or directory ]
|
|
62
|
+
* // since dir4 does not exist
|
|
63
|
+
* } else {
|
|
64
|
+
* console.log(results);
|
|
65
|
+
* }
|
|
66
|
+
* });
|
|
67
|
+
*
|
|
68
|
+
* // Using Promises
|
|
69
|
+
* async.concat(directoryList, fs.readdir)
|
|
70
|
+
* .then(results => {
|
|
71
|
+
* console.log(results);
|
|
72
|
+
* // [ 'file1.txt', 'file2.txt', 'file3.txt', 'file4.txt', file5.txt ]
|
|
73
|
+
* }).catch(err => {
|
|
74
|
+
* console.log(err);
|
|
41
75
|
* });
|
|
76
|
+
*
|
|
77
|
+
* // Error Handling
|
|
78
|
+
* async.concat(withMissingDirectoryList, fs.readdir)
|
|
79
|
+
* .then(results => {
|
|
80
|
+
* console.log(results);
|
|
81
|
+
* }).catch(err => {
|
|
82
|
+
* console.log(err);
|
|
83
|
+
* // [ Error: ENOENT: no such file or directory ]
|
|
84
|
+
* // since dir4 does not exist
|
|
85
|
+
* });
|
|
86
|
+
*
|
|
87
|
+
* // Using async/await
|
|
88
|
+
* async () => {
|
|
89
|
+
* try {
|
|
90
|
+
* let results = await async.concat(directoryList, fs.readdir);
|
|
91
|
+
* console.log(results);
|
|
92
|
+
* // [ 'file1.txt', 'file2.txt', 'file3.txt', 'file4.txt', file5.txt ]
|
|
93
|
+
* } catch (err) {
|
|
94
|
+
* console.log(err);
|
|
95
|
+
* }
|
|
96
|
+
* }
|
|
97
|
+
*
|
|
98
|
+
* // Error Handling
|
|
99
|
+
* async () => {
|
|
100
|
+
* try {
|
|
101
|
+
* let results = await async.concat(withMissingDirectoryList, fs.readdir);
|
|
102
|
+
* console.log(results);
|
|
103
|
+
* } catch (err) {
|
|
104
|
+
* console.log(err);
|
|
105
|
+
* // [ Error: ENOENT: no such file or directory ]
|
|
106
|
+
* // since dir4 does not exist
|
|
107
|
+
* }
|
|
108
|
+
* }
|
|
109
|
+
*
|
|
42
110
|
*/
|
|
43
111
|
function concat(coll, iteratee, callback) {
|
|
44
112
|
return (0, _concatLimit2.default)(coll, Infinity, iteratee, callback);
|
|
@@ -4,15 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
|
|
7
|
-
var _wrapAsync = require('./internal/wrapAsync');
|
|
7
|
+
var _wrapAsync = require('./internal/wrapAsync.js');
|
|
8
8
|
|
|
9
9
|
var _wrapAsync2 = _interopRequireDefault(_wrapAsync);
|
|
10
10
|
|
|
11
|
-
var _mapLimit = require('./mapLimit');
|
|
11
|
+
var _mapLimit = require('./mapLimit.js');
|
|
12
12
|
|
|
13
13
|
var _mapLimit2 = _interopRequireDefault(_mapLimit);
|
|
14
14
|
|
|
15
|
-
var _awaitify = require('./internal/awaitify');
|
|
15
|
+
var _awaitify = require('./internal/awaitify.js');
|
|
16
16
|
|
|
17
17
|
var _awaitify2 = _interopRequireDefault(_awaitify);
|
|
18
18
|
|
|
@@ -4,11 +4,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
|
|
7
|
-
var _concatLimit = require('./concatLimit');
|
|
7
|
+
var _concatLimit = require('./concatLimit.js');
|
|
8
8
|
|
|
9
9
|
var _concatLimit2 = _interopRequireDefault(_concatLimit);
|
|
10
10
|
|
|
11
|
-
var _awaitify = require('./internal/awaitify');
|
|
11
|
+
var _awaitify = require('./internal/awaitify.js');
|
|
12
12
|
|
|
13
13
|
var _awaitify2 = _interopRequireDefault(_awaitify);
|
|
14
14
|
|
|
@@ -4,15 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
|
|
7
|
-
var _createTester = require('./internal/createTester');
|
|
7
|
+
var _createTester = require('./internal/createTester.js');
|
|
8
8
|
|
|
9
9
|
var _createTester2 = _interopRequireDefault(_createTester);
|
|
10
10
|
|
|
11
|
-
var _eachOf = require('./eachOf');
|
|
11
|
+
var _eachOf = require('./eachOf.js');
|
|
12
12
|
|
|
13
13
|
var _eachOf2 = _interopRequireDefault(_eachOf);
|
|
14
14
|
|
|
15
|
-
var _awaitify = require('./internal/awaitify');
|
|
15
|
+
var _awaitify = require('./internal/awaitify.js');
|
|
16
16
|
|
|
17
17
|
var _awaitify2 = _interopRequireDefault(_awaitify);
|
|
18
18
|
|
|
@@ -46,13 +46,48 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
46
46
|
* @returns A Promise, if no callback is passed
|
|
47
47
|
* @example
|
|
48
48
|
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
49
|
+
* // dir1 is a directory that contains file1.txt, file2.txt
|
|
50
|
+
* // dir2 is a directory that contains file3.txt, file4.txt
|
|
51
|
+
* // dir3 is a directory that contains file5.txt
|
|
52
|
+
*
|
|
53
|
+
* // asynchronous function that checks if a file exists
|
|
54
|
+
* function fileExists(file, callback) {
|
|
55
|
+
* fs.access(file, fs.constants.F_OK, (err) => {
|
|
56
|
+
* callback(null, !err);
|
|
57
|
+
* });
|
|
58
|
+
* }
|
|
59
|
+
*
|
|
60
|
+
* async.detect(['file3.txt','file2.txt','dir1/file1.txt'], fileExists,
|
|
61
|
+
* function(err, result) {
|
|
62
|
+
* console.log(result);
|
|
63
|
+
* // dir1/file1.txt
|
|
64
|
+
* // result now equals the first file in the list that exists
|
|
65
|
+
* }
|
|
66
|
+
*);
|
|
67
|
+
*
|
|
68
|
+
* // Using Promises
|
|
69
|
+
* async.detect(['file3.txt','file2.txt','dir1/file1.txt'], fileExists)
|
|
70
|
+
* .then(result => {
|
|
71
|
+
* console.log(result);
|
|
72
|
+
* // dir1/file1.txt
|
|
54
73
|
* // result now equals the first file in the list that exists
|
|
74
|
+
* }).catch(err => {
|
|
75
|
+
* console.log(err);
|
|
55
76
|
* });
|
|
77
|
+
*
|
|
78
|
+
* // Using async/await
|
|
79
|
+
* async () => {
|
|
80
|
+
* try {
|
|
81
|
+
* let result = await async.detect(['file3.txt','file2.txt','dir1/file1.txt'], fileExists);
|
|
82
|
+
* console.log(result);
|
|
83
|
+
* // dir1/file1.txt
|
|
84
|
+
* // result now equals the file in the list that exists
|
|
85
|
+
* }
|
|
86
|
+
* catch (err) {
|
|
87
|
+
* console.log(err);
|
|
88
|
+
* }
|
|
89
|
+
* }
|
|
90
|
+
*
|
|
56
91
|
*/
|
|
57
92
|
function detect(coll, iteratee, callback) {
|
|
58
93
|
return (0, _createTester2.default)(bool => bool, (res, item) => item)(_eachOf2.default, coll, iteratee, callback);
|
|
@@ -4,15 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
|
|
7
|
-
var _createTester = require('./internal/createTester');
|
|
7
|
+
var _createTester = require('./internal/createTester.js');
|
|
8
8
|
|
|
9
9
|
var _createTester2 = _interopRequireDefault(_createTester);
|
|
10
10
|
|
|
11
|
-
var _eachOfLimit = require('./internal/eachOfLimit');
|
|
11
|
+
var _eachOfLimit = require('./internal/eachOfLimit.js');
|
|
12
12
|
|
|
13
13
|
var _eachOfLimit2 = _interopRequireDefault(_eachOfLimit);
|
|
14
14
|
|
|
15
|
-
var _awaitify = require('./internal/awaitify');
|
|
15
|
+
var _awaitify = require('./internal/awaitify.js');
|
|
16
16
|
|
|
17
17
|
var _awaitify2 = _interopRequireDefault(_awaitify);
|
|
18
18
|
|
|
@@ -4,15 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
|
|
7
|
-
var _createTester = require('./internal/createTester');
|
|
7
|
+
var _createTester = require('./internal/createTester.js');
|
|
8
8
|
|
|
9
9
|
var _createTester2 = _interopRequireDefault(_createTester);
|
|
10
10
|
|
|
11
|
-
var _eachOfLimit = require('./internal/eachOfLimit');
|
|
11
|
+
var _eachOfLimit = require('./internal/eachOfLimit.js');
|
|
12
12
|
|
|
13
13
|
var _eachOfLimit2 = _interopRequireDefault(_eachOfLimit);
|
|
14
14
|
|
|
15
|
-
var _awaitify = require('./internal/awaitify');
|
|
15
|
+
var _awaitify = require('./internal/awaitify.js');
|
|
16
16
|
|
|
17
17
|
var _awaitify2 = _interopRequireDefault(_awaitify);
|
|
18
18
|
|