From dc4f83f7a765720975a787c5a7b21273a7ae8773 Mon Sep 17 00:00:00 2001 From: 915dbfl Date: Wed, 15 Nov 2023 00:32:14 +0900 Subject: [PATCH] fix: use RTCDateTime instead of UTCDateTime #162 --- .../main/src/main/java/org/swm/att/home/alarm/AlarmManager.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/feature/main/src/main/java/org/swm/att/home/alarm/AlarmManager.kt b/feature/main/src/main/java/org/swm/att/home/alarm/AlarmManager.kt index 4f9ec613..fd13baf8 100644 --- a/feature/main/src/main/java/org/swm/att/home/alarm/AlarmManager.kt +++ b/feature/main/src/main/java/org/swm/att/home/alarm/AlarmManager.kt @@ -5,6 +5,7 @@ import android.app.PendingIntent import android.content.Context import android.content.Intent import org.swm.att.common_ui.util.Formatter +import org.swm.att.common_ui.util.getRTCDateTime import org.swm.att.common_ui.util.getUTCDateTime import java.util.Calendar import java.util.concurrent.TimeUnit @@ -37,7 +38,7 @@ object AlarmManager { pendingIntentList[preorderId] = pendingIntent alarmManager.setExact( AlarmManager.RTC, - alarmTime.time - TimeUnit.MINUTES.toMillis(10), + alarmTime.getRTCDateTime().time - TimeUnit.MINUTES.toMillis(10), pendingIntent ) }