Skip to content

Commit 8577250

Browse files
Fix: Refresh QS cards when the default section changes
1 parent 5741044 commit 8577250

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

WordPress/Classes/ViewRelated/Blog/My Site/MySiteSettings.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ protocol DefaultSectionProvider {
3434

3535
func setDefaultSection(_ tab: MySiteViewController.Section) {
3636
userDefaults.set(tab.rawValue, forKey: Constants.defaultSectionKey)
37+
QuickStartTourGuide.shared.refreshQuickStart()
3738
WPAnalytics.track(.mySiteDefaultTabExperimentVariantAssigned, properties: ["default_tab_experiment": experimentAssignment])
3839
}
3940

WordPress/Classes/ViewRelated/Blog/QuickStartTourGuide.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,11 @@ open class QuickStartTourGuide: NSObject {
181181
}
182182
}
183183

184+
/// Posts an empty notification to trigger updates to Quick Start Cards if needed.
185+
func refreshQuickStart() {
186+
NotificationCenter.default.post(name: .QuickStartTourElementChangedNotification, object: self)
187+
}
188+
184189
private func addSiteMenuWayPointIfNeeded(for tour: QuickStartTour) -> QuickStartTour {
185190

186191
if currentEntryPoint == .blogDashboard &&

0 commit comments

Comments
 (0)