Commit 6ca1d441 authored by Mario's avatar Mario

Merge branch 'dev' into 'dev'

Fixed caching Hubzilla default icon for empty profile photo

See merge request hubzilla/addons!162

(cherry picked from commit 4bbad722)

cc3ae9fc Fixed caching Hubzilla default icon for empty profile photo
parent 3e74e219
......@@ -941,6 +941,7 @@ function as_actor_store($url,$person_obj) {
if(! is_array($person_obj))
return;
$icon = '';
$name = $person_obj['name'];
if(! $name)
$name = $person_obj['preferredUsername'];
......@@ -1057,9 +1058,6 @@ function as_actor_store($url,$person_obj) {
);
}
if(! $icon)
$icon = z_root() . '/' . get_default_profile_photo(300);
$photos = import_xchan_photo($icon,$url);
$r = q("update xchan set xchan_photo_date = '%s', xchan_photo_l = '%s', xchan_photo_m = '%s', xchan_photo_s = '%s', xchan_photo_mimetype = '%s' where xchan_hash = '%s'",
dbescdate(datetime_convert()),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment