From 6e61a18af096b3c64600c4293003a0edab505fac Mon Sep 17 00:00:00 2001 From: Mario Danic Date: Fri, 12 Jan 2018 10:58:41 +0100 Subject: [PATCH] Fix notification crash Signed-off-by: Mario Danic --- .../services/firebase/MagicFirebaseMessagingService.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/nextcloud/talk/services/firebase/MagicFirebaseMessagingService.java b/app/src/main/java/com/nextcloud/talk/services/firebase/MagicFirebaseMessagingService.java index eaaf9581b..3801a50ee 100644 --- a/app/src/main/java/com/nextcloud/talk/services/firebase/MagicFirebaseMessagingService.java +++ b/app/src/main/java/com/nextcloud/talk/services/firebase/MagicFirebaseMessagingService.java @@ -31,6 +31,7 @@ import android.graphics.BitmapFactory; import android.media.RingtoneManager; import android.net.Uri; import android.os.Bundle; +import android.support.v4.app.NotificationCompat; import android.util.Base64; import android.util.Log; @@ -130,9 +131,9 @@ public class MagicFirebaseMessagingService extends FirebaseMessagingService { CRC32 crc32 = new CRC32(); - Notification.Builder notificationBuilder = new Notification.Builder(this) - .setSmallIcon(smallIcon) + NotificationCompat.Builder notificationBuilder = new NotificationCompat.Builder(this) .setLargeIcon(largeIcon) + .setSmallIcon(smallIcon) .setColor(getColor(R.color.colorPrimary)) .setCategory(category) .setPriority(priority)