diff --git a/mod/display.php b/mod/display.php index 25bda99d0..fe8e960f9 100644 --- a/mod/display.php +++ b/mod/display.php @@ -78,7 +78,7 @@ function display_init(App $a) } if (ActivityPub::isRequest()) { - goaway(str_replace('display/', 'object/', $a->query_string)); + goaway(str_replace('display/', 'objects/', $a->query_string)); } if ($item["id"] != $item["parent"]) { diff --git a/src/Model/Item.php b/src/Model/Item.php index 2c9be633a..19ab371d7 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -2361,7 +2361,7 @@ class Item extends BaseObject $guid = System::createUUID(); } - return self::getApp()->get_baseurl() . '/object/' . $guid; + return self::getApp()->get_baseurl() . '/objects/' . $guid; } /** diff --git a/src/Module/Object.php b/src/Module/Objects.php similarity index 81% rename from src/Module/Object.php rename to src/Module/Objects.php index 05aae84f8..c52a75196 100644 --- a/src/Module/Object.php +++ b/src/Module/Objects.php @@ -1,6 +1,6 @@ query_string)); + goaway(str_replace('objects/', 'display/', $a->query_string)); } $item = Item::selectFirst(['id'], ['guid' => $a->argv[1], 'wall' => true, 'private' => false]); diff --git a/src/Protocol/ActivityPub.php b/src/Protocol/ActivityPub.php index b5cd102a5..ef4a48479 100644 --- a/src/Protocol/ActivityPub.php +++ b/src/Protocol/ActivityPub.php @@ -663,7 +663,7 @@ class ActivityPub } elseif (DBA::isResult($conversation) && !empty($conversation['conversation-uri'])) { $context_uri = $conversation['conversation-uri']; } else { - $context_uri = str_replace('/object/', '/context/', $item['parent-uri']); + $context_uri = str_replace('/objects/', '/context/', $item['parent-uri']); } return $context_uri; } diff --git a/src/Protocol/Diaspora.php b/src/Protocol/Diaspora.php index 847809a36..551971e50 100644 --- a/src/Protocol/Diaspora.php +++ b/src/Protocol/Diaspora.php @@ -1598,7 +1598,7 @@ class Diaspora unset($parts['path']); $host_url = Network::unparseURL($parts); - return $host_url . '/object/' . $guid; + return $host_url . '/objects/' . $guid; } return ""; diff --git a/src/Protocol/OStatus.php b/src/Protocol/OStatus.php index 2eb8c5539..d56bacc67 100644 --- a/src/Protocol/OStatus.php +++ b/src/Protocol/OStatus.php @@ -2004,7 +2004,7 @@ class OStatus } if (intval($item["parent"]) > 0) { - $conversation_href = $conversation_uri = str_replace('/object/', '/context/', $item['parent-uri']); + $conversation_href = $conversation_uri = str_replace('/objects/', '/context/', $item['parent-uri']); if (isset($parent_item)) { $conversation = DBA::selectFirst('conversation', ['conversation-uri', 'conversation-href'], ['item-uri' => $parent_item]);