Add additional QR code login debug logs.

This commit is contained in:
John Preston 2020-02-12 19:36:05 +04:00
parent 6bbcec0c23
commit 5c079b0bbd
3 changed files with 7 additions and 1 deletions

View File

@ -70,9 +70,11 @@ void PhoneWidget::setupQrLogin() {
) | rpl::then(
account().appConfig().refreshed()
) | rpl::map([=] {
return account().appConfig().get<QString>(
const auto result = account().appConfig().get<QString>(
"qr_login_code",
"disabled");
DEBUG_LOG(("PhoneWidget.qr_login_code: %1").arg(result));
return result;
}) | rpl::filter([](const QString &value) {
return (value != "disabled");
}) | rpl::take(1) | rpl::start_with_next([=] {
@ -81,6 +83,8 @@ void PhoneWidget::setupQrLogin() {
tr::lng_phone_to_qr(tr::now));
qrLogin->show();
DEBUG_LOG(("PhoneWidget.qrLogin link created and shown."));
rpl::combine(
sizeValue(),
qrLogin->widthValue()

View File

@ -34,6 +34,7 @@ void StartWidget::submit() {
const auto qrLogin = account().appConfig().get<QString>(
"qr_login_code",
"disabled");
DEBUG_LOG(("qr_login_code: %1").arg(qrLogin));
if (qrLogin == "primary") {
goNext<QrWidget>();
} else {

View File

@ -47,6 +47,7 @@ void AppConfig::refresh() {
_data.emplace_or_assign(qs(data.vkey()), data.vvalue());
});
}
DEBUG_LOG(("getAppConfig result handled."));
}
_refreshed.fire({});
}).fail([=](const RPCError &error) {