File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
android/src/main/java/io/wazo/callkeep Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -53,6 +53,7 @@ const options = {
5353 channelId: ' com.company.my' ,
5454 channelName: ' Foreground service for my app' ,
5555 notificationTitle: ' My app is running on background' ,
56+ notiticationIcon: ' Path to the resource icon of the notification' ,
5657 },
5758 }
5859};
@@ -141,6 +142,7 @@ RNCallKeep.setForegroundServiceSettings({
141142 channelId: ' com.company.my' ,
142143 channelName: ' Foreground service for my app' ,
143144 notificationTitle: ' My app is running on background' ,
145+ notiticationIcon: ' Path to the resource icon of the notification' ,
144146});
145147```
146148
Original file line number Diff line number Diff line change @@ -240,10 +240,10 @@ private void startForegroundService() {
240240 .setPriority (NotificationManager .IMPORTANCE_MIN )
241241 .setCategory (Notification .CATEGORY_SERVICE );
242242
243- if (foregroundSettings .hasKey ("icon " )) {
243+ if (foregroundSettings .hasKey ("notificationIcon " )) {
244244 Context context = this .getApplicationContext ();
245245 Resources res = context .getResources ();
246- String smallIcon = foregroundSettings .getString ("icon " );
246+ String smallIcon = foregroundSettings .getString ("notificationIcon " );
247247 notificationBuilder .setSmallIcon (res .getIdentifier (smallIcon , "mipmap" , context .getPackageName ()));
248248 }
249249
You can’t perform that action at this time.
0 commit comments