Skip to content
Snippets Groups Projects
Commit 27fed830 authored by Konstantinos Sideris's avatar Konstantinos Sideris
Browse files

Retry initial sync on generic network errors (#422)

parent 28dda237
No related branches found
No related tags found
No related merge requests found
......@@ -1169,6 +1169,12 @@ ChatPage::initialSyncHandler(const mtx::responses::Sync &res, mtx::http::Request
nhlog::net()->error("initial sync error: {} {}", status_code, err_code);
// non http related errors
if (status_code <= 0 || status_code >= 600) {
startInitialSync();
return;
}
switch (status_code) {
case 502:
case 504:
......
......@@ -105,6 +105,9 @@ private slots:
//! Show the login page in the main window.
void showLoginPage()
{
if (modal_)
modal_->hide();
pageStack_->addWidget(login_page_);
pageStack_->setCurrentWidget(login_page_);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment