Skip to content

Commit

Permalink
feat(react-native-sdk): fix builder .set method and module imports
Browse files Browse the repository at this point in the history
  • Loading branch information
Calinteodor committed Jan 8, 2025
1 parent a9a9eb4 commit 3b4b6c2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
import android.app.NotificationChannel;
import android.app.NotificationManager;

import android.app.Service;
import android.content.Context;

import android.os.Build;
Expand All @@ -27,8 +28,6 @@

import org.jitsi.meet.sdk.log.JitsiMeetLogger;

import java.util.Random;

/**
* Helper class for creating the ongoing notification which is used with
* {@link JMOngoingConferenceService}. It allows the user to easily get back to the app
Expand Down Expand Up @@ -87,7 +86,7 @@ static Notification buildOngoingConferenceNotification(Context context) {
.setAutoCancel(false)
.setVisibility(NotificationCompat.VISIBILITY_PUBLIC)
.setOnlyAlertOnce(true)
.setSmallIcon(context.getResources().getIdentifier("ic_notification", "drawable", context.getPackageName())),
.setSmallIcon(context.getResources().getIdentifier("ic_notification", "drawable", context.getPackageName()))
.setForegroundServiceBehavior(NotificationCompat.FOREGROUND_SERVICE_IMMEDIATE);

return builder.build();
Expand Down
4 changes: 2 additions & 2 deletions react/features/mobile/react-native-sdk/middleware.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { NativeModules, Platform } from 'react-native';
import { NativeModules } from 'react-native';

import { getAppProp } from '../../base/app/functions';
import {
Expand Down Expand Up @@ -93,7 +93,7 @@ const { JMOngoingConference } = NativeModules;
* Before enabling media projection service control on Android,
* we need to check if native modules are being used or not.
*/
Platform.OS === 'android' && !externalAPIEnabled && StateListenerRegistry.register(
JMOngoingConference && !externalAPIEnabled && StateListenerRegistry.register(
state => state['features/base/conference'].conference,
(conference, previousConference) => {
if (!conference) {
Expand Down

0 comments on commit 3b4b6c2

Please sign in to comment.