From 957c1da6d073635fdba4df28dccbc29921924a46 Mon Sep 17 00:00:00 2001 From: shannon Date: Wed, 11 Dec 2024 16:03:43 -0500 Subject: [PATCH] Stop the refresh control when update is complete. Fixes IOS-348 --- Mastodon/Scene/Profile/ProfileViewController.swift | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Mastodon/Scene/Profile/ProfileViewController.swift b/Mastodon/Scene/Profile/ProfileViewController.swift index deba8b3c4..8f4c7cb2e 100644 --- a/Mastodon/Scene/Profile/ProfileViewController.swift +++ b/Mastodon/Scene/Profile/ProfileViewController.swift @@ -167,6 +167,12 @@ class ProfileViewController: UIViewController, MediaPreviewableViewController, A guard isViewLoaded else { return } // TODO: careful about resetting things if we failed to push edits + if !viewModel.state.isUpdating { + if refreshControl.isRefreshing { + refreshControl.endRefreshing() + } + } + // Bridge to the old way of doing things until we replace the UI sometime in the future updateHeader(viewModel) updateAboutView(viewModel)