mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-18 15:38:28 +02:00
Improve StateStore documentation and naming.
This commit is contained in:
@@ -37,7 +37,7 @@ class TemplateUserProfileViewModel: TemplateUserProfileViewModelType, TemplateUs
|
||||
var completion: ((TemplateUserProfileViewModelResult) -> Void)?
|
||||
|
||||
// MARK: - Setup
|
||||
|
||||
|
||||
static func makeTemplateUserProfileViewModel(templateUserProfileService: TemplateUserProfileServiceProtocol) -> TemplateUserProfileViewModelProtocol {
|
||||
return TemplateUserProfileViewModel(templateUserProfileService: templateUserProfileService)
|
||||
}
|
||||
@@ -72,14 +72,8 @@ class TemplateUserProfileViewModel: TemplateUserProfileViewModelType, TemplateUs
|
||||
done()
|
||||
}
|
||||
}
|
||||
|
||||
/// A redux style reducer
|
||||
///
|
||||
/// All modifications to state happen here.
|
||||
/// - Parameters:
|
||||
/// - state: The `inout` state to be modified,
|
||||
/// - action: The action that defines which state modification should take place.
|
||||
private static func reducer(state: inout TemplateUserProfileViewState, action: TemplateUserProfileStateAction) {
|
||||
|
||||
override class func reducer(state: inout TemplateUserProfileViewState, action: TemplateUserProfileStateAction) {
|
||||
switch action {
|
||||
case .updatePresence(let presence):
|
||||
state.presence = presence
|
||||
|
||||
Reference in New Issue
Block a user