@apify/utilities 2.29.0 → 2.29.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/cjs/index.cjs +17 -14
- package/cjs/index.cjs.map +1 -1
- package/cjs/index.d.ts +0 -2
- package/esm/index.d.mts +0 -2
- package/esm/index.mjs +17 -14
- package/esm/index.mjs.map +1 -1
- package/package.json +5 -5
package/cjs/index.cjs
CHANGED
|
@@ -1144,18 +1144,21 @@ __name(checkParamPrototypeOrThrow, "checkParamPrototypeOrThrow");
|
|
|
1144
1144
|
function promisifyServerListen(server) {
|
|
1145
1145
|
return async (port) => {
|
|
1146
1146
|
return new Promise((resolve, reject) => {
|
|
1147
|
-
|
|
1147
|
+
function removeListeners() {
|
|
1148
|
+
server.removeListener("error", onError);
|
|
1149
|
+
server.removeListener("listening", onListening);
|
|
1150
|
+
}
|
|
1151
|
+
__name(removeListeners, "removeListeners");
|
|
1152
|
+
function onError(err) {
|
|
1148
1153
|
removeListeners();
|
|
1149
1154
|
reject(err);
|
|
1150
|
-
}
|
|
1151
|
-
|
|
1155
|
+
}
|
|
1156
|
+
__name(onError, "onError");
|
|
1157
|
+
function onListening() {
|
|
1152
1158
|
removeListeners();
|
|
1153
1159
|
resolve();
|
|
1154
|
-
}
|
|
1155
|
-
|
|
1156
|
-
server.removeListener("error", onError);
|
|
1157
|
-
server.removeListener("listening", onListening);
|
|
1158
|
-
}, "removeListeners");
|
|
1160
|
+
}
|
|
1161
|
+
__name(onListening, "onListening");
|
|
1159
1162
|
server.on("error", onError);
|
|
1160
1163
|
server.on("listening", onListening);
|
|
1161
1164
|
server.listen(port);
|
|
@@ -1436,7 +1439,7 @@ function isBadForMongo(obj) {
|
|
|
1436
1439
|
__name(isBadForMongo, "isBadForMongo");
|
|
1437
1440
|
var _JsonVariable = class _JsonVariable {
|
|
1438
1441
|
constructor(name) {
|
|
1439
|
-
this
|
|
1442
|
+
__publicField(this, "name", name);
|
|
1440
1443
|
}
|
|
1441
1444
|
getToken() {
|
|
1442
1445
|
return `{{${this.name}}}`;
|
|
@@ -1543,7 +1546,7 @@ var CHECK_TYPES = /* @__PURE__ */ ((CHECK_TYPES2) => {
|
|
|
1543
1546
|
})(CHECK_TYPES || {});
|
|
1544
1547
|
var _HealthChecker = class _HealthChecker {
|
|
1545
1548
|
constructor(options) {
|
|
1546
|
-
this
|
|
1549
|
+
__publicField(this, "options", options);
|
|
1547
1550
|
__publicField(this, "checks");
|
|
1548
1551
|
__publicField(this, "redisPrefix");
|
|
1549
1552
|
__publicField(this, "redisTtlSecs");
|
|
@@ -1744,9 +1747,9 @@ __name(_InvalidVariableError, "InvalidVariableError");
|
|
|
1744
1747
|
var InvalidVariableError = _InvalidVariableError;
|
|
1745
1748
|
var _WebhookPayloadTemplate = class _WebhookPayloadTemplate {
|
|
1746
1749
|
constructor(template, allowedVariables = null, context = {}) {
|
|
1747
|
-
this
|
|
1748
|
-
this
|
|
1749
|
-
this
|
|
1750
|
+
__publicField(this, "template", template);
|
|
1751
|
+
__publicField(this, "allowedVariables", allowedVariables);
|
|
1752
|
+
__publicField(this, "context", context);
|
|
1750
1753
|
__publicField(this, "payload");
|
|
1751
1754
|
__publicField(this, "replacedVariables", []);
|
|
1752
1755
|
this.payload = template;
|
|
@@ -1973,7 +1976,7 @@ var CodeHashMetaKey = /* @__PURE__ */ ((CodeHashMetaKey2) => {
|
|
|
1973
1976
|
})(CodeHashMetaKey || {});
|
|
1974
1977
|
var _CodeHashManager = class _CodeHashManager {
|
|
1975
1978
|
constructor(secret) {
|
|
1976
|
-
this
|
|
1979
|
+
__publicField(this, "secret", secret);
|
|
1977
1980
|
}
|
|
1978
1981
|
/**
|
|
1979
1982
|
* Encodes object (e.g. input for actor) to a string hash and uses the `secret` to sign the hash.
|