mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
12 lines
394 B
Swift
12 lines
394 B
Swift
import Foundation
|
|
import Postbox
|
|
import SwiftSignalKit
|
|
import MtProtoKit
|
|
|
|
|
|
func updateAppChangelogState(transaction: Transaction, _ f: @escaping (AppChangelogState) -> AppChangelogState) {
|
|
transaction.updatePreferencesEntry(key: PreferencesKeys.appChangelogState, { current in
|
|
return PreferencesEntry(f((current?.get(AppChangelogState.self)) ?? AppChangelogState.default))
|
|
})
|
|
}
|