mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-12 01:54:26 +02:00
New avatar picture fields to better cope with changing avatars
This commit is contained in:
parent
d6c1889a20
commit
6f662b8c74
15 changed files with 143 additions and 59 deletions
|
@ -740,6 +740,7 @@ function diaspora_request($importer,$xml) {
|
|||
$new_relation = CONTACT_IS_FOLLOWER;
|
||||
|
||||
$r = q("UPDATE `contact` SET
|
||||
`avatar` = '%s',
|
||||
`photo` = '%s',
|
||||
`thumb` = '%s',
|
||||
`micro` = '%s',
|
||||
|
@ -752,6 +753,7 @@ function diaspora_request($importer,$xml) {
|
|||
`writable` = 1
|
||||
WHERE `id` = %d
|
||||
",
|
||||
dbesc($contact_record['photo']),
|
||||
dbesc($photos[0]),
|
||||
dbesc($photos[1]),
|
||||
dbesc($photos[2]),
|
||||
|
@ -2491,12 +2493,15 @@ function diaspora_profile($importer,$xml,$msg) {
|
|||
/// @TODO Update name on item['author-name'] if the name changed. See consume_feed()
|
||||
/// (Not doing this currently because D* protocol is scheduled for revision soon).
|
||||
|
||||
$r = q("UPDATE `contact` SET `name` = '%s', `nick` = '%s', `addr` = '%s', `name-date` = '%s', `photo` = '%s', `thumb` = '%s', `micro` = '%s', `avatar-date` = '%s' , `bd` = '%s', `location` = '%s', `about` = '%s', `keywords` = '%s', `gender` = '%s' WHERE `id` = %d AND `uid` = %d",
|
||||
$r = q("UPDATE `contact` SET `name` = '%s', `nick` = '%s', `addr` = '%s', `name-date` = '%s',
|
||||
`avatar` = '%s', `photo` = '%s', `thumb` = '%s', `micro` = '%s', `avatar-date` = '%s' , `bd` = '%s',
|
||||
`location` = '%s', `about` = '%s', `keywords` = '%s', `gender` = '%s' WHERE `id` = %d AND `uid` = %d",
|
||||
dbesc($name),
|
||||
dbesc($nick),
|
||||
dbesc($diaspora_handle),
|
||||
dbesc(datetime_convert()),
|
||||
dbesc($image_url),
|
||||
dbesc($images[0]),
|
||||
dbesc($images[1]),
|
||||
dbesc($images[2]),
|
||||
dbesc(datetime_convert()),
|
||||
|
@ -2516,7 +2521,7 @@ function diaspora_profile($importer,$xml,$msg) {
|
|||
}
|
||||
|
||||
update_gcontact(array("url" => $contact['url'], "network" => NETWORK_DIASPORA, "generation" => 2,
|
||||
"photo" => $image_url, "name" => $name, "location" => $location,
|
||||
"avatar" => $image_url, "name" => $name, "location" => $location,
|
||||
"about" => $about, "birthday" => $birthday, "gender" => $gender,
|
||||
"addr" => $diaspora_handle, "nick" => $nick, "keywords" => $keywords,
|
||||
"hide" => !$searchable, "nsfw" => $nsfw));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue