https://github.com/pedroslopez/whatsapp-web.js/issues/2799
https://stackoverflow.com/questions/78275662/error-after-scanning-qr-code-for-whatsapp-web-js?answertab=scoredesc#tab-top
בנתיב הבא -
/node_modules/whatsapp-web.js/src/webCache
LocalWebCache.js
לשנות לבא -
async persist(indexHtml) {
// extract version from index (e.g. manifest-2.2206.9.json -> 2.2206.9)
let version;
if (indexHtml.match(/manifest-([\d\\.]+)\.json/) === null) {
version = '2.2409.2';
} else {
version = indexHtml.match(/manifest-([\d\\.]+)\.json/)[1];
}
if (!version) return;
const filePath = path.join(this.path, `${version}.html`);
fs.mkdirSync(this.path, { recursive: true });
fs.writeFileSync(filePath, indexHtml);
}
ובתוך ספריית
/node_modules/whatsapp-web.js/src/util
קובץ -
Constants.js
webVersionCache: {
type: 'remote',
remotePath: 'https://raw.githubusercontent.com/wppconnect-team/wa-version/main/html/2.2412.54.html',
},