Update mtxclient to use new login parameters

fixes #558
This commit is contained in:
Nicolas Werner 2021-04-30 14:04:34 +02:00
parent b160baba4e
commit 7431b51d27
No known key found for this signature in database
GPG key ID: C8D75E610773F2D9
3 changed files with 7 additions and 5 deletions

View file

@ -362,7 +362,7 @@ if(USE_BUNDLED_MTXCLIENT)
FetchContent_Declare(
MatrixClient
GIT_REPOSITORY https://github.com/Nheko-Reborn/mtxclient.git
GIT_TAG v0.5.1
GIT_TAG 5d2f055ea9403770039ddf66b1900f890cd5cde7
)
set(BUILD_LIB_EXAMPLES OFF CACHE INTERNAL "")
set(BUILD_LIB_TESTS OFF CACHE INTERNAL "")

View file

@ -148,8 +148,7 @@ modules:
buildsystem: cmake-ninja
name: mtxclient
sources:
- commit: b19f1dc7e422f1bb217f02487567fc09e25e7d2b
tag: v0.5.1
- commit: 5d2f055ea9403770039ddf66b1900f890cd5cde7
type: git
url: https://github.com/Nheko-Reborn/mtxclient.git
- config-opts:

View file

@ -420,8 +420,11 @@ LoginPage::onLoginButtonClicked(LoginMethod loginMethod)
: deviceName_->text().toStdString(),
[this](const mtx::responses::Login &res, mtx::http::RequestErr err) {
if (err) {
showErrorMessage(error_label_,
QString::fromStdString(err->matrix_error.error));
auto error = err->matrix_error.error;
if (error.empty())
error = err->parse_error;
showErrorMessage(error_label_, QString::fromStdString(error));
emit errorOccurred();
return;
}