From 7e3448a8253a15547c5df076ee0a4e31e988ebc5 Mon Sep 17 00:00:00 2001 From: Ladislas de Toldi Date: Fri, 27 Oct 2023 18:06:33 +0200 Subject: [PATCH] :pencil2: (typos): Subscribe to update*s* not update --- .../UpdateProcess/Template/UpdateProcessTemplate.swift | 4 ++-- Apps/LekaUpdater/Sources/View/UpdateStatusDemoView.swift | 4 ++-- .../Sources/ViewModel/UpdateStatusViewModel.swift | 8 ++++---- .../_NewSystem/Views/TouchToSelectViewViewModel.swift | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Apps/LekaUpdater/Sources/Libs/UpdateProcess/Template/UpdateProcessTemplate.swift b/Apps/LekaUpdater/Sources/Libs/UpdateProcess/Template/UpdateProcessTemplate.swift index 93df47f44b..43fbde76b1 100644 --- a/Apps/LekaUpdater/Sources/Libs/UpdateProcess/Template/UpdateProcessTemplate.swift +++ b/Apps/LekaUpdater/Sources/Libs/UpdateProcess/Template/UpdateProcessTemplate.swift @@ -35,10 +35,10 @@ class UpdateProcessTemplate: UpdateProcessProtocol { public var sendingFileProgression = CurrentValueSubject(0.0) init() { - subscribeToStateUpdate() + subscribeToStateUpdates() } - private func subscribeToStateUpdate() { + private func subscribeToStateUpdates() { self.currentInternalState .receive(on: DispatchQueue.main) .sink(receiveCompletion: self.convertCompletion, receiveValue: self.convertReceivedValue) diff --git a/Apps/LekaUpdater/Sources/View/UpdateStatusDemoView.swift b/Apps/LekaUpdater/Sources/View/UpdateStatusDemoView.swift index 3e1d70c363..dc831ab3cc 100644 --- a/Apps/LekaUpdater/Sources/View/UpdateStatusDemoView.swift +++ b/Apps/LekaUpdater/Sources/View/UpdateStatusDemoView.swift @@ -16,14 +16,14 @@ class UpdateStatusDemoViewModel: ObservableObject { init() { self.updateProcessController = UpdateProcessController() - subscribeToStateUpdate() + subscribeToStateUpdates() } public func startUpdate() { updateProcessController.startUpdate() } - private func subscribeToStateUpdate() { + private func subscribeToStateUpdates() { self.updateProcessController.currentStage .receive(on: DispatchQueue.main) .sink { completion in diff --git a/Apps/LekaUpdater/Sources/ViewModel/UpdateStatusViewModel.swift b/Apps/LekaUpdater/Sources/ViewModel/UpdateStatusViewModel.swift index 7719552402..66d37a7fd6 100644 --- a/Apps/LekaUpdater/Sources/ViewModel/UpdateStatusViewModel.swift +++ b/Apps/LekaUpdater/Sources/ViewModel/UpdateStatusViewModel.swift @@ -43,12 +43,12 @@ class UpdateStatusViewModel: ObservableObject { } init() { - subscribeToStateUpdate() - subscribeToSendingFileProgressionUpdate() + subscribeToStateUpdates() + subscribeToSendingFileProgressionUpdates() subscribeToRobotIsChargingUpdates() } - private func subscribeToStateUpdate() { + private func subscribeToStateUpdates() { self.updateProcessController.currentStage .receive(on: DispatchQueue.main) .sink { completion in @@ -107,7 +107,7 @@ class UpdateStatusViewModel: ObservableObject { .store(in: &cancellables) } - private func subscribeToSendingFileProgressionUpdate() { + private func subscribeToSendingFileProgressionUpdates() { self.updateProcessController.sendingFileProgression .receive(on: DispatchQueue.main) .sink(receiveValue: { progression in diff --git a/Modules/GameEngineKit/Sources/_NewSystem/Views/TouchToSelectViewViewModel.swift b/Modules/GameEngineKit/Sources/_NewSystem/Views/TouchToSelectViewViewModel.swift index b1f520b5e5..74f295ee06 100644 --- a/Modules/GameEngineKit/Sources/_NewSystem/Views/TouchToSelectViewViewModel.swift +++ b/Modules/GameEngineKit/Sources/_NewSystem/Views/TouchToSelectViewViewModel.swift @@ -16,14 +16,14 @@ class TouchToSelectViewViewModel: ObservableObject { init(choices: [SelectionChoice]) { self.gameplay = GameplaySelectAllRightAnswers( choices: choices.map { GameplaySelectionChoiceModel(choice: $0) }) - subscribeToGameplaySelectionChoicesUpdate() + subscribeToGameplaySelectionChoicesUpdates() } public func onChoiceTapped(choice: GameplaySelectionChoiceModel) { gameplay.process(choice) } - private func subscribeToGameplaySelectionChoicesUpdate() { + private func subscribeToGameplaySelectionChoicesUpdates() { gameplay.choices .receive(on: DispatchQueue.main) .sink {