[mirotalksfu] - add redirect on leave room, update dep.

هذا الالتزام موجود في:
Miroslav Pejic
2023-10-27 14:20:53 +02:00
الأصل 9c856a0f86
التزام c3e459e999
7 ملفات معدلة مع 35 إضافات و22 حذوفات

عرض الملف

@@ -11,7 +11,7 @@ if (location.href.substr(0, 5) !== 'https') location.href = 'https' + location.h
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
* @version 1.1.3
* @version 1.1.4
*
*/
@@ -28,6 +28,11 @@ let survey = {
url: 'https://www.questionpro.com/t/AUs7VZq02P',
};
let redirect = {
enabled: true,
url: '/newroom',
};
const _PEER = {
audioOn: '<i class="fas fa-microphone"></i>',
audioOff: '<i style="color: red;" class="fas fa-microphone-slash"></i>',
@@ -2135,10 +2140,10 @@ function handleRoomClientEvents() {
console.log('Room event: Client save recording before to exit');
rc.stopRecording();
}
if (survey.enabled) {
if (survey && survey.enabled) {
leaveFeedback();
} else {
openURL('/newroom');
redirect && redirect.enabled ? openURL(redirect.url) : openURL('/newroom');
}
});
}

عرض الملف

@@ -9,7 +9,7 @@
* @license For commercial or closed source, contact us at license.mirotalk@gmail.com or purchase directly via CodeCanyon
* @license CodeCanyon: https://codecanyon.net/item/mirotalk-sfu-webrtc-realtime-video-conferences/40769970
* @author Miroslav Pejic - miroslav.pejic.85@gmail.com
* @version 1.1.3
* @version 1.1.4
*
*/
@@ -344,6 +344,8 @@ class RoomClient {
async handleRoomInfo(room) {
console.log('07.0 ----> Room Survey', room.survey);
survey = room.survey;
console.log('07.0 ----> Room Leave Redirect', room.redirect);
redirect = room.redirect;
let peers = new Map(JSON.parse(room.peers));
participantsCount = peers.size;
for (let peer of Array.from(peers.keys()).filter((id) => id == this.peer_id)) {