修改路径

dev/supplier-email-drawer
Lei OT 6 months ago
parent a638b7a315
commit 9b4b7d666d

@ -25,7 +25,7 @@ exports.sendText = async ctx => {
try {
const sockMsg = wsToSend.sendTextMessage(to, content);
console.log(JSON.stringify(sockMsg, undefined, 2));
await upsertOutboundMessage(null, { ...ctx.request.body, id: sockMsg.key });
await upsertOutboundMessage(null, { ...ctx.request.body, id: sockMsg.key || sockMsg.id });
return 'Message sent successfully'; // { wsToSend, ret: 'Message sent successfully' };
} catch (error) {
console.error('Error sending message:', error);

@ -1,5 +1,5 @@
// core/index.js
const sessionServicesI = require('./services/session');
const sessionServicesI = require('./handler/sessionStore');
// Create the instances here
const sessionService = sessionServicesI();

@ -5,7 +5,7 @@ const server = require('./server');
const { port } = require('./config').server;
const { setupWhatsappHandler, resetCurrentConnection } = require('./core/services/whatsappHandler');
const { setupWhatsappHandler, resetCurrentConnection } = require('./core/handler/whatsappHandler');
async function bootstrap() {
/**

Loading…
Cancel
Save