fix(conference): API left event.
This commit is contained in:
parent
fa3888991f
commit
d01cfc8466
|
@ -488,10 +488,13 @@ class ConferenceConnector {
|
||||||
* call in hangup() to resolve when all operations are finished.
|
* call in hangup() to resolve when all operations are finished.
|
||||||
*/
|
*/
|
||||||
function disconnect() {
|
function disconnect() {
|
||||||
connection.disconnect();
|
const onDisconnected = () => {
|
||||||
APP.API.notifyConferenceLeft(APP.conference.roomName);
|
APP.API.notifyConferenceLeft(APP.conference.roomName);
|
||||||
|
|
||||||
return Promise.resolve();
|
return Promise.resolve();
|
||||||
|
};
|
||||||
|
|
||||||
|
return connection.disconnect().then(onDisconnected, onDisconnected);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -2603,8 +2606,7 @@ export default {
|
||||||
leaveRoomAndDisconnect() {
|
leaveRoomAndDisconnect() {
|
||||||
APP.store.dispatch(conferenceWillLeave(room));
|
APP.store.dispatch(conferenceWillLeave(room));
|
||||||
|
|
||||||
return room.leave()
|
return room.leave().then(disconnect, disconnect);
|
||||||
.then(disconnect, disconnect);
|
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue