Skip to content

Commit

Permalink
Remove configuration of notification channel for badges
Browse files Browse the repository at this point in the history
  • Loading branch information
tevincent committed Jul 11, 2024
1 parent 1b795bf commit 020b8b7
Showing 1 changed file with 1 addition and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ import android.os.Build
import androidx.annotation.RequiresApi
import androidx.core.app.NotificationCompat
import androidx.core.app.NotificationManagerCompat
import com.infomaniak.lib.core.R

abstract class NotificationUtilsCore {

Expand Down Expand Up @@ -68,7 +67,7 @@ abstract class NotificationUtilsCore {
}

@RequiresApi(Build.VERSION_CODES.O)
protected fun Context.buildNotificationChannel(
protected fun buildNotificationChannel(
channelId: String,
name: String,
importance: Int,
Expand All @@ -78,18 +77,6 @@ abstract class NotificationUtilsCore {
return NotificationChannel(channelId, name, importance).apply {
description?.let { this.description = it }
groupId?.let { group = it }
when (importance) {
NotificationManager.IMPORTANCE_HIGH -> {
enableLights(true)
setShowBadge(true)
lightColor = getColor(R.color.primary)
}
else -> {
enableLights(false)
setShowBadge(false)
enableVibration(false)
}
}
}
}

Expand Down

0 comments on commit 020b8b7

Please sign in to comment.