Merge branch 'dev' into 'dev'

emoji reactions from hubzilla becoming top level posts on zap because of missing object

See merge request hubzilla/core!1689
This commit is contained in:
Mario 2019-07-12 13:00:14 +02:00
commit e5370971d6
2 changed files with 14 additions and 1 deletions

View File

@ -487,6 +487,19 @@ class Activity {
$ret['type'] = self::activity_mapper($i['verb']); $ret['type'] = self::activity_mapper($i['verb']);
if($ret['type'] === 'emojiReaction') {
// There may not be an object for these items for legacy reasons - it should be the conversation parent.
$p = q("select * from item where mid = '%s' and uid = %d",
dbesc($i['parent_mid']),
intval($i['uid'])
);
if($p) {
xchan_query($p,true);
$p = fetch_post_tags($p,true);
$i['obj'] = self::encode_item($p[0]);
}
}
$ret['id'] = ((strpos($i['mid'],'http') === 0) ? $i['mid'] : z_root() . '/activity/' . urlencode($i['mid'])); $ret['id'] = ((strpos($i['mid'],'http') === 0) ? $i['mid'] : z_root() . '/activity/' . urlencode($i['mid']));

View File

@ -83,7 +83,7 @@ web server platforms.
Example config scripts are available for these platforms in the install Example config scripts are available for these platforms in the install
directory. Apache and nginx have the most support. directory. Apache and nginx have the most support.
- PHP 5.6 or later. - PHP 7.1 or later.
- PHP *command line* access with register_argc_argv set to true in the - PHP *command line* access with register_argc_argv set to true in the
php.ini file - and with no hosting provider restrictions on the use of php.ini file - and with no hosting provider restrictions on the use of