fix: Video Conf information block not updating automatically (#29682)

Co-authored-by: Diego Sampaio <chinello@gmail.com>
pull/27922/head^2
Guilherme Gazzo 3 years ago committed by GitHub
parent cb4048a911
commit ba1d0c5d63
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 7
      apps/meteor/server/modules/listeners/listeners.module.ts
  2. 6
      apps/meteor/server/services/video-conference/service.ts
  3. 1
      packages/core-services/src/Events.ts

@ -132,6 +132,13 @@ export class ListenersModule {
},
);
service.onEvent('room.video-conference', ({ rid, callId }) => {
/* deprecated */
(notifications.notifyRoom as any)(rid, callId);
notifications.notifyRoom(rid, 'videoconf', callId);
});
service.onEvent('presence.status', ({ user }) => {
const { _id, username, name, status, statusText, roles } = user;
if (!status || !username) {

@ -41,7 +41,6 @@ import { updateCounter } from '../../../app/statistics/server/functions/updateSt
import { readSecondaryPreferred } from '../../database/readSecondaryPreferred';
import { availabilityErrors } from '../../../lib/videoConference/constants';
import { callbacks } from '../../../lib/callbacks';
import { Notifications } from '../../../app/notifications/server';
import { canAccessRoomIdAsync } from '../../../app/authorization/server/functions/canAccessRoom';
import { i18n } from '../../lib/i18n';
@ -419,10 +418,7 @@ export class VideoConfService extends ServiceClassInternal implements IVideoConf
}
private notifyVideoConfUpdate(rid: IRoom['_id'], callId: VideoConference['_id']): void {
/* deprecated */
(Notifications.notifyRoom as any)(rid, callId);
Notifications.notifyRoom(rid, 'videoconf', callId);
void api.broadcast('room.video-conference', { rid, callId });
}
private async endCall(callId: VideoConference['_id']): Promise<void> {

@ -36,6 +36,7 @@ import type { AutoUpdateRecord } from './types/IMeteor';
type ClientAction = 'inserted' | 'updated' | 'removed' | 'changed';
export type EventSignatures = {
'room.video-conference': (params: { rid: string; callId: string }) => void;
'shutdown': (params: Record<string, string[]>) => void;
'$services.changed': (info: { localService: boolean }) => void;
'accounts.login': (info: { userId: string; connection: ISocketConnection }) => void;

Loading…
Cancel
Save