Skip to content
Snippets Groups Projects
Unverified Commit d13a1c64 authored by Nicolas Werner's avatar Nicolas Werner Committed by GitHub
Browse files

Apply suggestions from code review

parent ebe0cd79
No related branches found
No related tags found
No related merge requests found
......@@ -193,7 +193,7 @@ LoginPage::loginError(const QString &msg)
auto rect = QFontMetrics(font()).boundingRect(msg);
int width = rect.width();
int height = rect.height();
error_label_->setFixedHeight(qCeil(width / 200 * height));
error_label_->setFixedHeight(qCeil(width / 200) * height);
error_label_->setText(msg);
}
......@@ -211,7 +211,7 @@ LoginPage::isMatrixIdValid()
QRegularExpressionValidator v(QRegularExpression("@.+?:.{3,}"), this);
QString s = matrixid_input_->text();
int pos = 0;
return v.validate(s, pos);
return v.validate(s, pos) == QValidator::Acceptable;
}
void
......
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