diff --git a/Mastodon/Scene/Profile/Header/View/ProfileHeaderView.swift b/Mastodon/Scene/Profile/Header/View/ProfileHeaderView.swift index 78430cb3..1a6e1053 100644 --- a/Mastodon/Scene/Profile/Header/View/ProfileHeaderView.swift +++ b/Mastodon/Scene/Profile/Header/View/ProfileHeaderView.swift @@ -407,8 +407,14 @@ extension ProfileHeaderView { override func traitCollectionDidChange(_ previousTraitCollection: UITraitCollection?) { super.traitCollectionDidChange(previousTraitCollection) - - updateLayoutMargins() + + // workaround enter background breaking the layout issue + switch UIApplication.shared.applicationState { + case .active: + updateLayoutMargins() + default: + break + } } }