]> git.mxchange.org Git - friendica.git/commitdiff
Issue 8967: Fix avatar in top bar
authorMichael <heluecht@pirati.ca>
Tue, 4 Aug 2020 20:15:42 +0000 (20:15 +0000)
committerMichael <heluecht@pirati.ca>
Tue, 4 Aug 2020 20:15:42 +0000 (20:15 +0000)
view/theme/frio/theme.php

index dcbeccc301ee487598af535aa44e0ffd0999be91..3ac04fced5308ee81053ac99b104a48479f60588 100644 (file)
@@ -195,8 +195,7 @@ function frio_remote_nav($a, &$nav)
        // this isn't optimal because the contact query will be done now twice
        $fields = ['id', 'url', 'avatar', 'micro', 'name', 'nick', 'baseurl'];
        if (local_user() && !empty($a->user['uid'])) {
-               $remoteUser = Contact::getById($a->user['uid'], $fields);
-               $remoteUser['name'] = $a->user['username'];
+               $remoteUser = DBA::selectFirst('contact', $fields, ['uid' => $a->user['uid'], 'self' => true]);
        } elseif (!local_user() && remote_user()) {
                $remoteUser = Contact::getById(remote_user(), $fields);
                $nav['remote'] = DI::l10n()->t('Guest');