mirror of
https://github.com/EvolutionAPI/evolution-api.git
synced 2025-07-22 20:12:02 -06:00
changed returned sessions on typebot status change
This commit is contained in:
parent
5975117636
commit
9aba51cb45
@ -57,7 +57,7 @@ export class TypebotService {
|
||||
|
||||
if (session) {
|
||||
if (status === 'closed') {
|
||||
findData.sessions.splice(findData.sessions.indexOf(session), 1);
|
||||
const found_session : Session[] = findData.sessions.splice(findData.sessions.indexOf(session), 1);
|
||||
|
||||
const typebotData = {
|
||||
enabled: findData.enabled,
|
||||
@ -68,7 +68,7 @@ export class TypebotService {
|
||||
delay_message: findData.delay_message,
|
||||
unknown_message: findData.unknown_message,
|
||||
listening_from_me: findData.listening_from_me,
|
||||
sessions: findData.sessions,
|
||||
sessions: found_session,
|
||||
};
|
||||
|
||||
this.create(instance, typebotData);
|
||||
@ -106,7 +106,7 @@ export class TypebotService {
|
||||
delay_message: findData.delay_message,
|
||||
unknown_message: findData.unknown_message,
|
||||
listening_from_me: findData.listening_from_me,
|
||||
sessions: findData.sessions,
|
||||
sessions: findData.sessions.splice(findData.sessions.indexOf(session), 1),
|
||||
};
|
||||
|
||||
this.create(instance, typebotData);
|
||||
|
Loading…
Reference in New Issue
Block a user