mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-20 06:15:11 +00:00
add conversation element and more logging
This commit is contained in:
parent
c48aae55af
commit
62e2df4c96
2 changed files with 8 additions and 0 deletions
|
@ -221,6 +221,13 @@ class Activity {
|
|||
|
||||
if($i['id'] != $i['parent']) {
|
||||
$ret['inReplyTo'] = ((strpos($i['parent_mid'],'http') === 0) ? $i['parent_mid'] : z_root() . '/item/' . urlencode($i['parent_mid']));
|
||||
$cnv = get_iconfig($i['parent'],'ostatus','conversation');
|
||||
}
|
||||
if(! $cnv) {
|
||||
$cnv = get_iconfig($i,'ostatus','conversation');
|
||||
}
|
||||
if($cnv) {
|
||||
$ret['conversation'] = $cnv;
|
||||
}
|
||||
|
||||
if($i['mimetype'] === 'text/bbcode') {
|
||||
|
|
|
@ -236,6 +236,7 @@ class Queue {
|
|||
$headers = [];
|
||||
$headers['Content-Type'] = 'application/ld+json; profile="https://www.w3.org/ns/activitystreams"' ;
|
||||
$ret = $outq['outq_msg'];
|
||||
logger('ActivityPub send: ' . $ret, LOGGER_DATA);
|
||||
$headers['Digest'] = HTTPSig::generate_digest_header($ret);
|
||||
$xhead = HTTPSig::create_sig($headers,$channel['channel_prvkey'],channel_url($channel));
|
||||
$result = z_post_url($outq['outq_posturl'],$outq['outq_msg'],$retries,[ 'headers' => $xhead ]);
|
||||
|
|
Loading…
Reference in a new issue