fix: connections page not updating on session changes

This commit is contained in:
canove
2020-10-03 16:12:26 -03:00
parent 3fd0784f60
commit 70e89996a3
2 changed files with 3 additions and 9 deletions

View File

@@ -9,12 +9,6 @@ import DeleteWhatsAppService from "../services/WhatsappService/DeleteWhatsAppSer
import ListWhatsAppsService from "../services/WhatsappService/ListWhatsAppsService";
import ShowWhatsAppService from "../services/WhatsappService/ShowWhatsAppService";
import UpdateWhatsAppService from "../services/WhatsappService/UpdateWhatsAppService";
// import Yup from "yup";
// import Whatsapp from "../models/Whatsapp";
// import { getIO } from "../libs/socket";
// import { getWbot, initWbot, removeWbot } from "../libs/wbot";
// import wbotMessageListener from "../services/wbotMessageListener";
// import wbotMonitor from "../services/wbotMonitor";
interface WhatsappData {
name: string;

View File

@@ -21,7 +21,7 @@ const wbotMonitor = (whatsapp: Whatsapp): void => {
console.log(err);
}
io.emit("session", {
io.emit("whatsappSession", {
action: "update",
session: whatsapp
});
@@ -40,7 +40,7 @@ const wbotMonitor = (whatsapp: Whatsapp): void => {
console.log(err);
}
io.emit("session", {
io.emit("whatsappSession", {
action: "update",
session: whatsapp
});
@@ -55,7 +55,7 @@ const wbotMonitor = (whatsapp: Whatsapp): void => {
console.log(err);
}
io.emit("session", {
io.emit("whatsappSession", {
action: "update",
session: whatsapp
});