mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-19 16:35:19 +00:00
reply collection issue using nomadic uri
This commit is contained in:
parent
51df69ecb7
commit
a4f4ab2794
1 changed files with 4 additions and 11 deletions
|
@ -31,19 +31,12 @@ class Replies extends Controller
|
|||
|
||||
// do we have the item (at all)?
|
||||
|
||||
$test = q(
|
||||
"select * from item where mid = '%s' $item_normal limit 1",
|
||||
dbesc(z_root() . '/activity/' . $item_mid)
|
||||
$test = q("select * from item where mid like '%s' $item_normal limit 1",
|
||||
dbesc(z_root() . protect_sprintf('/%/') . $item_mid)
|
||||
);
|
||||
|
||||
if (!$test) {
|
||||
$test = q(
|
||||
"select * from item where mid = '%s' $item_normal limit 1",
|
||||
dbesc(z_root() . '/item/' . $item_mid)
|
||||
);
|
||||
if (!$test) {
|
||||
http_status_exit(404, 'Not found');
|
||||
}
|
||||
http_status_exit(404, 'Not found');
|
||||
}
|
||||
// process an authenticated fetch
|
||||
$zot6Hubloc = false;
|
||||
|
@ -163,7 +156,7 @@ class Replies extends Controller
|
|||
http_status_exit(403, 'Forbidden');
|
||||
}
|
||||
|
||||
$collection = ZlibActivity::encode_item_collection($nitems, 'replies/' . $item_mid, 'OrderedCollection', true, z_root() . '/channel/' . $chan['channel_address'], count($nitems));
|
||||
$collection = ZlibActivity::encode_item_collection($nitems, 'replies/' . $item_mid, 'OrderedCollection', true, Channel::getDidResolver($chan, true), count($nitems));
|
||||
if ($portable_id && (!intval($items[0]['item_private']))) {
|
||||
ThreadListener::store(z_root() . '/activity/' . $item_mid, $portable_id);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue