aboutsummaryrefslogtreecommitdiffstats
path: root/include/items.php
diff options
context:
space:
mode:
authorChris Case <kahotep@bunda.dreamhost.com>2011-05-22 19:20:12 -0700
committerChris Case <kahotep@bunda.dreamhost.com>2011-05-22 19:20:12 -0700
commit150830d38c2191d2e55a373043af176208d4b430 (patch)
tree44cad869fb3a152e40b1111a35ac0c7774e3e703 /include/items.php
parent991885f1d40b8a8f16cd17c028f5c93eba69a5f3 (diff)
parent44a22c29155fa3beeed7cd5d0add30818e409891 (diff)
downloadvolse-hubzilla-150830d38c2191d2e55a373043af176208d4b430.tar.gz
volse-hubzilla-150830d38c2191d2e55a373043af176208d4b430.tar.bz2
volse-hubzilla-150830d38c2191d2e55a373043af176208d4b430.zip
Merge remote branch 'upstream/master'
Diffstat (limited to 'include/items.php')
-rw-r--r--include/items.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/items.php b/include/items.php
index 55b17158a..cbf5e4d24 100644
--- a/include/items.php
+++ b/include/items.php
@@ -384,6 +384,9 @@ function get_atom_elements($feed,$item) {
else
$res['private'] = 0;
+ $extid = $item->get_item_tags(NAMESPACE_DFRN,'extid');
+ if($extid && $extid[0]['data'])
+ $res['extid'] = $extid[0]['data'];
$rawlocation = $item->get_item_tags(NAMESPACE_DFRN, 'location');
if($rawlocation)
@@ -634,6 +637,7 @@ function item_store($arr,$force_parent = false) {
$arr['wall'] = ((x($arr,'wall')) ? intval($arr['wall']) : 0);
$arr['uri'] = ((x($arr,'uri')) ? notags(trim($arr['uri'])) : random_string());
+ $arr['extid'] = ((x($arr,'extid')) ? notags(trim($arr['extid'])) : '');
$arr['author-name'] = ((x($arr,'author-name')) ? notags(trim($arr['author-name'])) : '');
$arr['author-link'] = ((x($arr,'author-link')) ? notags(trim($arr['author-link'])) : '');
$arr['author-avatar'] = ((x($arr,'author-avatar')) ? notags(trim($arr['author-avatar'])) : '');
@@ -1568,6 +1572,10 @@ function atom_entry($item,$type,$author,$owner,$comment = false) {
if(($item['private']) || strlen($item['allow_cid']) || strlen($item['allow_gid']) || strlen($item['deny_cid']) || strlen($item['deny_gid']))
$o .= '<dfrn:private>1</dfrn:private>' . "\r\n";
+ if($item['extid'])
+ $o .= '<dfrn:extid>' . $item['extid'] . '</dfrn:extid>' . "\r\n";
+
+
$verb = construct_verb($item);
$o .= '<as:verb>' . xmlify($verb) . '</as:verb>' . "\r\n";
$actobj = construct_activity_object($item);