Fixed crash in share QR box on copy without profile photo.

This commit is contained in:
23rd 2024-10-14 22:32:59 +03:00
parent b41ac0fc2a
commit 5eafe96525

View file

@ -889,7 +889,9 @@ void FillPeerQrBox(
usernameValue()).current().toUpper();
const auto link = rpl::variable<QString>(linkValue());
const auto textWidth = font->width(username);
const auto top = userpicMedia->image(photoSize);
const auto top = photoSize
? userpicMedia->image(photoSize)
: QImage();
const auto weak = Ui::MakeWeak(box);
crl::async([=] {