Remove obsolete code (IOS-192)

This commit is contained in:
Nathan Mattes 2024-02-14 16:52:27 +01:00
parent 68e29d2aea
commit 6bcbc0ac07
3 changed files with 0 additions and 25 deletions

View File

@ -100,8 +100,6 @@ extension HomeTimelineViewModel.LoadLatestState {
await enter(state: Idle.self)
viewModel.homeTimelineNavigationBarTitleViewModel.receiveLoadingStateCompletion(.finished)
viewModel.context.instanceService.updateMutesAndBlocks()
// stop refresher if no new statuses
let statuses = response.value
let newStatuses = statuses.filter { status in !latestStatusIDs.contains(where: { $0 == status.reblog?.id || $0 == status.id }) }

View File

@ -92,9 +92,6 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
// trigger authenticated user account update
AppContext.shared.authenticationService.updateActiveUserAccountPublisher.send()
// update mutes and blocks and remove related data
AppContext.shared.instanceService.updateMutesAndBlocks()
if let shortcutItem = savedShortCutItem {
Task {

View File

@ -121,23 +121,3 @@ extension InstanceService {
.eraseToAnyPublisher()
}
}
public extension InstanceService {
func updateMutesAndBlocks() {
Task {
for authBox in authenticationService?.mastodonAuthenticationBoxes ?? [] {
do {
try await apiService?.getMutes(
authenticationBox: authBox
)
try await apiService?.getBlocked(
authenticationBox: authBox
)
} catch {
}
}
}
}
}