skylerss 2.0.2 → 2.0.4
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/lib/Utils/generics.js
CHANGED
|
@@ -36,7 +36,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.isWABusinessPlatform = exports.getCodeFromWSError = exports.getCallStatusFromNode = exports.getErrorCodeFromStreamError = exports.getStatusFromReceiptType = exports.generateMdTagPrefix = exports.fetchLatestWaWebVersion = exports.fetchLatestskylersVersion = exports.
|
|
39
|
+
exports.isWABusinessPlatform = exports.getCodeFromWSError = exports.getCallStatusFromNode = exports.getErrorCodeFromStreamError = exports.getStatusFromReceiptType = exports.generateMdTagPrefix = exports.fetchLatestWaWebVersion = exports.fetchLatestskylersVersion = exports.printQRIfNecessaryListener = exports.bindWaitForConnectionUpdate = exports.generateMessageID = exports.generateMessageIDV2 = exports.delayCancellable = exports.delay = exports.debouncedTimeout = exports.unixTimestampSeconds = exports.toNumber = exports.encodeBigEndian = exports.generateRegistrationId = exports.encodeNewsletterMessage = exports.encodeWAMessage = exports.unpadRandomMax16 = exports.writeRandomPadMax16 = exports.getKeyAuthor = exports.BufferJSON = exports.getPlatformId = exports.Browsers = void 0;
|
|
40
40
|
exports.promiseTimeout = promiseTimeout;
|
|
41
41
|
exports.bindWaitForEvent = bindWaitForEvent;
|
|
42
42
|
exports.trimUndefined = trimUndefined;
|
|
@@ -281,27 +281,7 @@ const fetchLatestskylersVersion = async (options = {}) => {
|
|
|
281
281
|
};
|
|
282
282
|
exports.fetchLatestskylersVersion = fetchLatestskylersVersion;
|
|
283
283
|
|
|
284
|
-
|
|
285
|
-
try {
|
|
286
|
-
const { data } = await axios_1.default.get('https://registry.npmjs.org/skylers', {
|
|
287
|
-
...options,
|
|
288
|
-
responseType: 'json'
|
|
289
|
-
});
|
|
290
|
-
const versionStr = data.version;
|
|
291
|
-
const [major, minor, patch] = versionStr.split('.').map(Number);
|
|
292
|
-
return {
|
|
293
|
-
version: [major, minor, patch],
|
|
294
|
-
isLatest: true
|
|
295
|
-
};
|
|
296
|
-
} catch (error) {
|
|
297
|
-
return {
|
|
298
|
-
version: skylers_version_json_1.version,
|
|
299
|
-
isLatest: false,
|
|
300
|
-
error
|
|
301
|
-
};
|
|
302
|
-
}
|
|
303
|
-
};
|
|
304
|
-
exports.fetchLatestBaileysVersion = fetchLatestBaileysVersion;
|
|
284
|
+
// fetchLatestBaileysVersion removed to maintain independence. Use fetchLatestskylersVersion instead.
|
|
305
285
|
|
|
306
286
|
/**
|
|
307
287
|
* A utility that fetches the latest web version of whatsapp.
|
|
@@ -8,8 +8,7 @@ const WAProto_1 = require("../../WAProto");
|
|
|
8
8
|
const auth_utils_1 = require("./auth-utils");
|
|
9
9
|
const generics_1 = require("./generics");
|
|
10
10
|
// We need to lock files due to the fact that we are using async functions to read and write files
|
|
11
|
-
//
|
|
12
|
-
// https://github.com/nodejs/node/issues/26338
|
|
11
|
+
// Locked files due to async read/write operations
|
|
13
12
|
// Use a Map to store mutexes for each file path
|
|
14
13
|
const fileLocks = new Map();
|
|
15
14
|
// Get or create a mutex for a specific file path
|
package/lib/index.js
CHANGED
|
@@ -30,7 +30,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
|
|
|
30
30
|
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
31
31
|
for (var p in m)
|
|
32
32
|
if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p))
|
|
33
|
-
__createBinding(exports,
|
|
33
|
+
__createBinding(exports, m, p);
|
|
34
34
|
};
|
|
35
35
|
var __importDefault = (this && this.__importDefault) || function(mod) {
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|