- ver 1.2.47 :

- corretto errore di modifica scheda
- aggiunto scraping (fase 1)
This commit is contained in:
Surya Paolo
2025-05-16 10:26:55 +02:00
parent 1da0e0f4b5
commit 7e50299854
9 changed files with 194 additions and 38 deletions

View File

@@ -534,14 +534,14 @@ connectToDatabase(connectionUrl, options)
try {
// console.log('checkdir', folderprof);
if (!tools.existsSync(folderprof)) {
if (!tools.isFileExists(folderprof)) {
console.log('*** Creadir', folderprof);
await fs.mkdirSync(folderprof);
}
folderprof = dir + 'profile/' + myuser.username + '/' + table;
// console.log('checkdir', folderprof);
if (!tools.existsSync(folderprof)) {
if (!tools.isFileExists(folderprof)) {
console.log('creadir', folderprof);
await fs.mkdirSync(folderprof);
}
@@ -691,10 +691,10 @@ connectToDatabase(connectionUrl, options)
}
// Verifica esistenza file
if (!tools.existsSync(keyPath)) {
if (!tools.isFileExists(keyPath)) {
throw new Error(`Chiave privata non trovata: ${keyPath}`);
}
if (!tools.existsSync(certPath)) {
if (!tools.isFileExists(certPath)) {
throw new Error(`Certificato non trovato: ${certPath}`);
}
@@ -944,7 +944,7 @@ connectToDatabase(connectionUrl, options)
if (scriptProcess) scriptProcess.kill();
const scriptPath = path.join(__dirname, '..', '..', parsed.scriptName);
if (!tools.existsSync(scriptPath)) {
if (!tools.isFileExists(scriptPath)) {
return ws.send(JSON.stringify({ type: 'error', data: 'Script non trovato o non autorizzato' }));
}