Issue 5811: "objects" instead of "object"

pull/5812/head
Michael 2018-10-02 20:12:38 +00:00
rodzic c02dea7b02
commit 518d461a8f
6 zmienionych plików z 6 dodań i 6 usunięć

Wyświetl plik

@ -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"]) {

Wyświetl plik

@ -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;
}
/**

Wyświetl plik

@ -24,7 +24,7 @@ class Object extends BaseModule
}
if (!ActivityPub::isRequest()) {
goaway(str_replace('object/', 'display/', $a->query_string));
goaway(str_replace('objects/', 'display/', $a->query_string));
}
$item = Item::selectFirst(['id'], ['guid' => $a->argv[1], 'wall' => true, 'private' => false]);

Wyświetl plik

@ -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;
}

Wyświetl plik

@ -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 "";

Wyświetl plik

@ -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]);