diff --git a/vector/src/main/java/im/vector/riotx/core/services/VectorSyncService.kt b/vector/src/main/java/im/vector/riotx/core/services/VectorSyncService.kt index 31b56c4e47..b6b8fbf06a 100644 --- a/vector/src/main/java/im/vector/riotx/core/services/VectorSyncService.kt +++ b/vector/src/main/java/im/vector/riotx/core/services/VectorSyncService.kt @@ -45,15 +45,13 @@ class VectorSyncService : SyncService() { } override fun onStart(isInitialSync: Boolean) { - if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { - val notificationSubtitleRes = if (isInitialSync) { - R.string.notification_initial_sync - } else { - R.string.notification_listening_for_events - } - val notification = notificationUtils.buildForegroundServiceNotification(notificationSubtitleRes, false) - startForeground(NotificationUtils.NOTIFICATION_ID_FOREGROUND_SERVICE, notification) + val notificationSubtitleRes = if (isInitialSync) { + R.string.notification_initial_sync + } else { + R.string.notification_listening_for_events } + val notification = notificationUtils.buildForegroundServiceNotification(notificationSubtitleRes, false) + startForeground(NotificationUtils.NOTIFICATION_ID_FOREGROUND_SERVICE, notification) } override fun onRescheduleAsked(userId: String, isInitialSync: Boolean, delay: Long) {