Updates
This commit is contained in:
parent
c5a063a19a
commit
5458f37dee
@ -102,6 +102,7 @@ class MyFirebaseMessagingService : FirebaseMessagingService() {
|
|||||||
.setContentTitle(getString(R.string.fcm_message))
|
.setContentTitle(getString(R.string.fcm_message))
|
||||||
.setContentText(messageBody)
|
.setContentText(messageBody)
|
||||||
.setAutoCancel(true)
|
.setAutoCancel(true)
|
||||||
|
.setPriority(NotificationCompat.PRIORITY_MAX)
|
||||||
.setSound(defaultSoundUri)
|
.setSound(defaultSoundUri)
|
||||||
.setContentIntent(pendingIntent)
|
.setContentIntent(pendingIntent)
|
||||||
|
|
||||||
@ -111,9 +112,10 @@ class MyFirebaseMessagingService : FirebaseMessagingService() {
|
|||||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
|
||||||
val channel = NotificationChannel(
|
val channel = NotificationChannel(
|
||||||
channelId,
|
channelId,
|
||||||
"Channel human readable title",
|
"TeaSense",
|
||||||
NotificationManager.IMPORTANCE_DEFAULT,
|
NotificationManager.IMPORTANCE_DEFAULT,
|
||||||
)
|
)
|
||||||
|
|
||||||
notificationManager.createNotificationChannel(channel)
|
notificationManager.createNotificationChannel(channel)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user