From: Hypolite Petovan Date: Tue, 20 Dec 2016 17:50:36 +0000 (-0500) Subject: Merge remote-tracking branch 'friendica/develop' into bug/fix-diaspora-people-links X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=e8e1f9253da63a11c813708f5baaeba2d9f537f3;p=friendica.git Merge remote-tracking branch 'friendica/develop' into bug/fix-diaspora-people-links # Conflicts: # include/follow.php --- e8e1f9253da63a11c813708f5baaeba2d9f537f3 diff --cc include/diaspora.php index fcc9309395,3b4832e74f..4af1b6daa1 --- a/include/diaspora.php +++ b/include/diaspora.php @@@ -2359,12 -2286,11 +2359,12 @@@ class Diaspora // Attach embedded pictures to the body if ($data->photo) { - foreach ($data->photo AS $photo) + foreach ($data->photo AS $photo) { $body = "[img]".unxmlify($photo->remote_photo_path). unxmlify($photo->remote_photo_name)."[/img]\n".$body; + } - $datarray["object-type"] = ACTIVITY_OBJ_PHOTO; + $datarray["object-type"] = ACTIVITY_OBJ_IMAGE; } else { $datarray["object-type"] = ACTIVITY_OBJ_NOTE; diff --cc include/follow.php index 2cb72a6068,7a3514b3a7..779ecf082d --- a/include/follow.php +++ b/include/follow.php @@@ -295,14 -279,18 +279,24 @@@ function new_contact($uid,$url,$interac intval($uid) ); - if(count($r)) { - if(($contact['network'] == NETWORK_OSTATUS) && (strlen($contact['notify']))) { - require_once('include/salmon.php'); - slapper($r[0],$contact['notify'],$slap); + if (dbm::is_result($r)) { + if (($contact['network'] == NETWORK_OSTATUS) && (strlen($contact['notify']))) { + + // create a follow slap + $item = array(); + $item['verb'] = ACTIVITY_FOLLOW; + $item['follow'] = $contact["url"]; + $slap = ostatus::salmon($item, $r[0]); + slapper($r[0], $contact['notify'], $slap); } ++<<<<<<< HEAD + if($contact['network'] == NETWORK_DIASPORA) { + require_once('include/diaspora.php'); + $ret = Diaspora::send_share($a->user,$contact); ++======= + if ($contact['network'] == NETWORK_DIASPORA) { + $ret = diaspora::send_share($a->user,$contact); ++>>>>>>> friendica/develop logger('share returns: '.$ret); } }