@ -56,6 +56,11 @@ class NotificationSettingsViewModel: SessionTableViewModel<NoNav, NotificationSe
// / j u s t i n c a s e t h e d a t a b a s e h a s c h a n g e d b e t w e e n t h e t w o r e a d s - u n f o r t u n a t e l y i t d o e s n ' t l o o k l i k e t h e r e i s a w a y t o p r e v e n t t h i s
private lazy var _observableSettingsData : ObservableData = ValueObservation
. trackingConstantRegion { db -> [ SectionModel ] in
let notificationSound : Preferences . Sound = db [ . defaultNotificationSound ]
. defaulting ( to : Preferences . Sound . defaultNotificationSound )
let previewType : Preferences . NotificationPreviewType = db [ . preferencesNotificationPreviewType ]
. defaulting ( to : Preferences . NotificationPreviewType . defaultPreviewType )
return [
SectionModel (
model : . strategy ,
@ -90,11 +95,7 @@ class NotificationSettingsViewModel: SessionTableViewModel<NoNav, NotificationSe
id : . styleSound ,
title : " NOTIFICATIONS_STYLE_SOUND_TITLE " . localized ( ) ,
rightAccessory : . dropDown (
. dynamicString (
type : Preferences . Sound . self ,
key : . defaultNotificationSound ,
value : { $0 . defaulting ( to : . defaultNotificationSound ) . displayName }
)
. dynamicString { notificationSound . displayName }
) ,
onTap : { [ weak self ] in
self ? . transitionToScreen (
@ -122,11 +123,7 @@ class NotificationSettingsViewModel: SessionTableViewModel<NoNav, NotificationSe
title : " NOTIFICATIONS_STYLE_CONTENT_TITLE " . localized ( ) ,
subtitle : " NOTIFICATIONS_STYLE_CONTENT_DESCRIPTION " . localized ( ) ,
rightAccessory : . dropDown (
. dynamicString (
type : Preferences . NotificationPreviewType . self ,
key : . preferencesNotificationPreviewType ,
value : { $0 . defaulting ( to : . defaultPreviewType ) . name }
)
. dynamicString { previewType . name }
) ,
onTap : { [ weak self ] in
self ? . transitionToScreen (