mirror of
https://github.com/friendica/friendica
synced 2024-11-10 04:22:54 +00:00
Merge pull request #11247 from MrPetovan/bug/notices
Check the existence of the `uid` field before accessing it in Module\Photo
This commit is contained in:
commit
18e0fb375b
1 changed files with 2 additions and 1 deletions
|
@ -288,9 +288,10 @@ class Photo extends BaseModule
|
|||
}
|
||||
}
|
||||
|
||||
If (($contact['uid'] != 0) && empty($contact['photo']) && empty($contact['avatar'])) {
|
||||
if (!empty($contact['uid']) && empty($contact['photo']) && empty($contact['avatar'])) {
|
||||
$contact = Contact::getByURL($contact['url'], false, ['avatar', 'photo', 'xmpp', 'addr']);
|
||||
}
|
||||
|
||||
if (!empty($contact['photo']) && !empty($contact['avatar'])) {
|
||||
// Fetch photo directly
|
||||
$resourceid = MPhoto::ridFromURI($contact['photo']);
|
||||
|
|
Loading…
Reference in a new issue