@open-wa/wa-automate 4.51.3 → 4.51.5
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.
@@ -446,7 +446,7 @@ function initBrowser(sessionId, config = {}, spinner) {
|
|
446
446
|
let args = [...puppeteer_config_1.puppeteerConfig.chromiumArgs, ...((config === null || config === void 0 ? void 0 : config.chromiumArgs) || [])];
|
447
447
|
if (config === null || config === void 0 ? void 0 : config.multiDevice) {
|
448
448
|
args = args.filter(x => x != '--incognito');
|
449
|
-
config["userDataDir"] = config["userDataDir"] || `${(config === null || config === void 0 ? void 0 : config.sessionDataPath) || (config === null || config === void 0 ? void 0 : config.inDocker) ? '/sessions' : (config === null || config === void 0 ? void 0 : config.sessionDataPath) || '.'}/_IGNORE_${(config === null || config === void 0 ? void 0 : config.sessionId) || 'session'}`;
|
449
|
+
config["userDataDir"] = config["userDataDir"] || `${(config === null || config === void 0 ? void 0 : config.sessionDataPath) || ((config === null || config === void 0 ? void 0 : config.inDocker) ? '/sessions' : (config === null || config === void 0 ? void 0 : config.sessionDataPath) || '.')}/_IGNORE_${(config === null || config === void 0 ? void 0 : config.sessionId) || 'session'}`;
|
450
450
|
spinner === null || spinner === void 0 ? void 0 : spinner.info('MD Enabled, turning off incognito mode.');
|
451
451
|
spinner === null || spinner === void 0 ? void 0 : spinner.info(`Data dir: ${config["userDataDir"]}`);
|
452
452
|
}
|
@@ -170,7 +170,7 @@ function create(config = {}) {
|
|
170
170
|
/**
|
171
171
|
* Check if the IGNORE folder exists, therefore, assume that the session is MD.
|
172
172
|
*/
|
173
|
-
const mdDir = config["userDataDir"] || `${(config === null || config === void 0 ? void 0 : config.inDocker) ? '/sessions' : (config === null || config === void 0 ? void 0 : config.sessionDataPath) || '.'}/_IGNORE_${(config === null || config === void 0 ? void 0 : config.sessionId) || 'session'}`;
|
173
|
+
const mdDir = config["userDataDir"] || `${(config === null || config === void 0 ? void 0 : config.sessionDataPath) || ((config === null || config === void 0 ? void 0 : config.inDocker) ? '/sessions' : (config === null || config === void 0 ? void 0 : config.sessionDataPath) || '.')}/_IGNORE_${(config === null || config === void 0 ? void 0 : config.sessionId) || 'session'}`;
|
174
174
|
if (process.env.AUTO_MD && fs.existsSync(mdDir) && !(config === null || config === void 0 ? void 0 : config.multiDevice)) {
|
175
175
|
spinner.info(`Multi-Device directory detected. multiDevice set to true.`);
|
176
176
|
config.multiDevice = true;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@open-wa/wa-automate",
|
3
|
-
"version": "4.51.
|
3
|
+
"version": "4.51.5",
|
4
4
|
"licenseCheckUrl": "https://funcs.openwa.dev/license-check",
|
5
5
|
"brokenMethodReportUrl": "https://funcs.openwa.dev/report-bm",
|
6
6
|
"patches": "https://cdn.openwa.dev/patches.json",
|
@@ -16,6 +16,7 @@
|
|
16
16
|
"build:skipmid": "tsc && npm run build:lib",
|
17
17
|
"build:lib": "ts-node prebuild.ts",
|
18
18
|
"docs": "npm run --prefix docs-v3 deploy_with_ssh_ci",
|
19
|
+
"types:publish": "npm run --prefix types-only pub",
|
19
20
|
"watch": "npm run build && tsc-watch ./src/index.ts --outDir ./dist --onSuccess \"node ./dist/index.js\" --onFailure \"echo Error while compiling\" --compiler typescript/bin/tsc",
|
20
21
|
"clean": "rm -rf session && rm -rf dist",
|
21
22
|
"clean:full": "rm -rf node_modules && npm run clean",
|