1
1
Fork 0

Merge pull request #4088 from annando/api-external-url

API: Path to post added / "external_url" support
This commit is contained in:
Hypolite Petovan 2017-12-17 10:57:46 -05:00 committed by GitHub
commit 691e4561e6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1326,6 +1326,7 @@ function api_status_show($type)
'lang' => "", 'lang' => "",
'statusnet_html' => $converted["html"], 'statusnet_html' => $converted["html"],
'statusnet_conversation_id' => $lastwall['parent'], 'statusnet_conversation_id' => $lastwall['parent'],
'external_url' => System::baseUrl() . "/display/" . $lastwall['guid'],
); );
if (count($converted["attachments"]) > 0) { if (count($converted["attachments"]) > 0) {
@ -1414,6 +1415,7 @@ function api_users_show($type)
'favorited' => $lastwall['starred'] ? true : false, 'favorited' => $lastwall['starred'] ? true : false,
'statusnet_html' => $converted["html"], 'statusnet_html' => $converted["html"],
'statusnet_conversation_id' => $lastwall['parent'], 'statusnet_conversation_id' => $lastwall['parent'],
'external_url' => System::baseUrl() . "/display/" . $lastwall['guid'],
); );
if (count($converted["attachments"]) > 0) { if (count($converted["attachments"]) > 0) {
@ -2846,6 +2848,7 @@ function api_format_items($r, $user_info, $filter_user = false, $type = "json")
//'entities' => NULL, //'entities' => NULL,
'statusnet_html' => $converted["html"], 'statusnet_html' => $converted["html"],
'statusnet_conversation_id' => $item['parent'], 'statusnet_conversation_id' => $item['parent'],
'external_url' => System::baseUrl() . "/display/" . $item['guid'],
'friendica_activities' => api_format_items_activities($item, $type), 'friendica_activities' => api_format_items_activities($item, $type),
); );