mirror of
https://gitcode.com/GitHub_Trending/ji/jitsi-meet.git
synced 2025-12-30 11:22:31 +00:00
Use logger instead of console
This commit is contained in:
committed by
Дамян Минков
parent
79a67049a9
commit
7bbd06c9f4
@@ -1,4 +1,5 @@
|
||||
// @flow
|
||||
import { getLogger } from 'jitsi-meet-logger';
|
||||
import type { Dispatch } from 'redux';
|
||||
|
||||
import UIEvents from '../../../service/UI/UIEvents';
|
||||
@@ -25,6 +26,8 @@ import { RemoteVideoMenu } from './components';
|
||||
|
||||
declare var APP: Object;
|
||||
|
||||
const logger = getLogger(__filename);
|
||||
|
||||
/**
|
||||
* Hides the remote video menu.
|
||||
*
|
||||
@@ -46,7 +49,7 @@ export function muteLocal(enable: boolean, mediaType: MEDIA_TYPE) {
|
||||
const isAudio = mediaType === MEDIA_TYPE.AUDIO;
|
||||
|
||||
if (!isAudio && mediaType !== MEDIA_TYPE.VIDEO) {
|
||||
console.error(`Unsupported media type: ${mediaType}`);
|
||||
logger.error(`Unsupported media type: ${mediaType}`);
|
||||
|
||||
return;
|
||||
}
|
||||
@@ -71,7 +74,7 @@ export function muteLocal(enable: boolean, mediaType: MEDIA_TYPE) {
|
||||
export function muteRemote(participantId: string, mediaType: MEDIA_TYPE) {
|
||||
return (dispatch: Dispatch<any>) => {
|
||||
if (mediaType !== MEDIA_TYPE.AUDIO && mediaType !== MEDIA_TYPE.VIDEO) {
|
||||
console.error(`Unsupported media type: ${mediaType}`);
|
||||
logger.error(`Unsupported media type: ${mediaType}`);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user