mirror of
https://github.com/iSoron/uhabits.git
synced 2025-12-06 09:08:52 -06:00
Removed an if statement
Removed the check if a summary was already shown.
This commit is contained in:
@@ -46,8 +46,6 @@ class AndroidNotificationTray
|
|||||||
|
|
||||||
private val generalLoopNotificationGroup = "generalLoopHabitsNotificationGroup"
|
private val generalLoopNotificationGroup = "generalLoopHabitsNotificationGroup"
|
||||||
|
|
||||||
private var summaryShown = false
|
|
||||||
|
|
||||||
override fun removeNotification(id: Int)
|
override fun removeNotification(id: Int)
|
||||||
{
|
{
|
||||||
NotificationManagerCompat.from(context).cancel(id)
|
NotificationManagerCompat.from(context).cancel(id)
|
||||||
@@ -60,14 +58,9 @@ class AndroidNotificationTray
|
|||||||
{
|
{
|
||||||
val notificationManager = NotificationManagerCompat.from(context)
|
val notificationManager = NotificationManagerCompat.from(context)
|
||||||
|
|
||||||
if(! summaryShown)
|
val summary = buildSummary(reminderTime)
|
||||||
{
|
|
||||||
val summary = buildSummary(reminderTime)
|
|
||||||
|
|
||||||
notificationManager.notify(Int.MAX_VALUE, summary)
|
notificationManager.notify(Int.MAX_VALUE, summary)
|
||||||
|
|
||||||
summaryShown = true
|
|
||||||
}
|
|
||||||
|
|
||||||
val notification = buildNotification(habit, reminderTime, timestamp)
|
val notification = buildNotification(habit, reminderTime, timestamp)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user