@@ -71,12 +71,8 @@ PageList::PageList(QObject *parent)
71 // If there was a system update installed, skip until the last page to just greet the user
71 // If there was a system update installed, skip until the last page to just greet the user
72 QSettings settings;
72 QSettings settings;
73 if (settings.value(QStringLiteral("Wizard/SkipUntilFinishedPage")).toBool()) {
73 if (settings.value(QStringLiteral("Wizard/SkipUntilFinishedPage")).toBool()) {
74− const QString lastPage = m_pages.lastKey();
74+ while (m_pages.count() > 1) {
75− for (auto it = m_pages.begin(); it != m_pages.end(); ++it) {
75+ m_pages.erase(m_pages.begin());
76− const QString page = it.key();
77− if (Q_UNLIKELY(page != lastPage)) {
78− m_pages.remove(page);
82 // ... and reset it again for the next run
78 // ... and reset it again for the next run