mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-17 02:05:19 +02:00
Merge remote-tracking branch 'friendica/develop' into bug/fix-diaspora-people-links
# Conflicts: # include/follow.php
This commit is contained in:
commit
e8e1f9253d
148 changed files with 12178 additions and 11976 deletions
|
@ -57,7 +57,7 @@ function do_like($item_id, $verb) {
|
|||
dbesc($item_id)
|
||||
);
|
||||
|
||||
if(! $item_id || (! count($r))) {
|
||||
if(! $item_id || (! dbm::is_result($r))) {
|
||||
logger('like: no item ' . $item_id);
|
||||
return false;
|
||||
}
|
||||
|
@ -78,7 +78,7 @@ function do_like($item_id, $verb) {
|
|||
intval($item['contact-id']),
|
||||
intval($item['uid'])
|
||||
);
|
||||
if(! count($r))
|
||||
if(! dbm::is_result($r))
|
||||
return false;
|
||||
if(! $r[0]['self'])
|
||||
$remote_owner = $r[0];
|
||||
|
@ -90,7 +90,7 @@ function do_like($item_id, $verb) {
|
|||
WHERE `contact`.`self` = 1 AND `contact`.`uid` = %d LIMIT 1",
|
||||
intval($owner_uid)
|
||||
);
|
||||
if(count($r))
|
||||
if (dbm::is_result($r))
|
||||
$owner = $r[0];
|
||||
|
||||
if(! $owner) {
|
||||
|
@ -112,7 +112,7 @@ function do_like($item_id, $verb) {
|
|||
intval($_SESSION['visitor_id']),
|
||||
intval($owner_uid)
|
||||
);
|
||||
if(count($r))
|
||||
if (dbm::is_result($r))
|
||||
$contact = $r[0];
|
||||
}
|
||||
if(! $contact) {
|
||||
|
@ -135,7 +135,7 @@ function do_like($item_id, $verb) {
|
|||
dbesc($item_id), dbesc($item_id), dbesc($item['uri'])
|
||||
);
|
||||
|
||||
if(count($r)) {
|
||||
if (dbm::is_result($r)) {
|
||||
$like_item = $r[0];
|
||||
|
||||
// Already voted, undo it
|
||||
|
@ -163,7 +163,7 @@ function do_like($item_id, $verb) {
|
|||
$post_type = (($item['resource-id']) ? t('photo') : t('status'));
|
||||
if($item['object-type'] === ACTIVITY_OBJ_EVENT)
|
||||
$post_type = t('event');
|
||||
$objtype = (($item['resource-id']) ? ACTIVITY_OBJ_PHOTO : ACTIVITY_OBJ_NOTE );
|
||||
$objtype = (($item['resource-id']) ? ACTIVITY_OBJ_IMAGE : ACTIVITY_OBJ_NOTE );
|
||||
$link = xmlify('<link rel="alternate" type="text/html" href="' . $a->get_baseurl() . '/display/' . $owner['nickname'] . '/' . $item['id'] . '" />' . "\n") ;
|
||||
$body = $item['body'];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue