Skip to content

Commit

Permalink
fix(android): use notification sound for notifications, not alarm (#2743
Browse files Browse the repository at this point in the history
)
  • Loading branch information
dibyendusaha authored Jul 7, 2020
1 parent 25505d2 commit b2d50f9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public void createChannel(JSObject channel) {
}
AudioAttributes audioAttributes = new AudioAttributes.Builder()
.setContentType(AudioAttributes.CONTENT_TYPE_SONIFICATION)
.setUsage(AudioAttributes.USAGE_ALARM).build();
.setUsage(AudioAttributes.USAGE_NOTIFICATION).build();
Uri soundUri = Uri.parse(ContentResolver.SCHEME_ANDROID_RESOURCE + "://" + context.getPackageName() + "/raw/" + sound);
notificationChannel.setSound(soundUri, audioAttributes);
}
Expand Down

0 comments on commit b2d50f9

Please sign in to comment.