Skip to content
This repository was archived by the owner on Jan 14, 2025. It is now read-only.

Commit 3ea54f5

Browse files
committed
Fix channel_id of notification.
1 parent bbe9b1d commit 3ea54f5

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

android/src/main/java/com/dieam/reactnativepushnotification/modules/RNPushNotificationHelper.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,8 +331,6 @@ public void sendToNotificationCentre(Bundle bundle) {
331331

332332
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { // API 26 and higher
333333
channel_id = channel_id + "-" + soundName;
334-
335-
notification.setChannelId(channel_id);
336334
}
337335
}
338336
}
@@ -383,6 +381,7 @@ public void sendToNotificationCentre(Bundle bundle) {
383381

384382
checkOrCreateChannel(notificationManager, channel_id, soundUri, priority, vibratePattern);
385383

384+
notification.setChannelId(channel_id);
386385
notification.setContentIntent(pendingIntent);
387386

388387
JSONArray actionsArray = null;

0 commit comments

Comments
 (0)