Migrated Kraken's getUser to Helix (#2260)
This commit is contained in:
@@ -580,25 +580,14 @@ void UserInfoPopup::updateUserData()
|
||||
|
||||
this->userId_ = user.id;
|
||||
|
||||
this->ui_.nameLabel->setText(user.displayName);
|
||||
this->setWindowTitle(TEXT_TITLE.arg(user.displayName));
|
||||
this->ui_.viewCountLabel->setText(TEXT_VIEWS.arg(user.viewCount));
|
||||
this->ui_.createdDateLabel->setText(
|
||||
TEXT_CREATED.arg(user.createdAt.section("T", 0, 0)));
|
||||
this->ui_.userIDLabel->setText(TEXT_USER_ID + user.id);
|
||||
this->ui_.userIDLabel->setProperty("copy-text", user.id);
|
||||
|
||||
this->ui_.viewCountLabel->setText(TEXT_VIEWS.arg(user.viewCount));
|
||||
getKraken()->getUser(
|
||||
user.id,
|
||||
[this, hack](const auto &user) {
|
||||
if (!hack.lock())
|
||||
{
|
||||
return;
|
||||
}
|
||||
this->ui_.nameLabel->setText(user.displayName);
|
||||
this->setWindowTitle(TEXT_TITLE.arg(user.displayName));
|
||||
this->ui_.createdDateLabel->setText(
|
||||
TEXT_CREATED.arg(user.createdAt.section("T", 0, 0)));
|
||||
},
|
||||
[] {
|
||||
// failure
|
||||
});
|
||||
if (isInStreamerMode() &&
|
||||
getSettings()->streamerModeHideUsercardAvatars)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user