aboutsummaryrefslogtreecommitdiffstats
path: root/include/feedutils.php
diff options
context:
space:
mode:
authorredmatrix <git@macgirvin.com>2016-06-01 21:48:54 -0700
committerredmatrix <git@macgirvin.com>2016-06-01 21:48:54 -0700
commita9d7acda279ebb7f2b3cd61a91a5e1d8b590dcf2 (patch)
treede0ac6910e13926df60cfed458e50310c5642055 /include/feedutils.php
parentb1259876bf398880e7b0c1b44d90f94983243e72 (diff)
downloadvolse-hubzilla-a9d7acda279ebb7f2b3cd61a91a5e1d8b590dcf2.tar.gz
volse-hubzilla-a9d7acda279ebb7f2b3cd61a91a5e1d8b590dcf2.tar.bz2
volse-hubzilla-a9d7acda279ebb7f2b3cd61a91a5e1d8b590dcf2.zip
the rest of the schema updates - WARNING: some third party plugins may fail; e.g. embedphotos and chess. $item['object'] is now $item['obj'] and $photo['type'] is $photo['mimetype'], $photo['scale'] is $photo['imgscale'] and $photo['data'] is now $photo['content']. There are a number of other changes, but these are the ones noted to cause issues with third-party plugins. The project plugins have been updated. Please note any new issues as this effort touched a lot of code in a lot of files.
Diffstat (limited to 'include/feedutils.php')
-rw-r--r--include/feedutils.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/include/feedutils.php b/include/feedutils.php
index fb938cfdd..685b2f982 100644
--- a/include/feedutils.php
+++ b/include/feedutils.php
@@ -144,9 +144,9 @@ function construct_verb($item) {
function construct_activity_object($item) {
- if($item['object']) {
+ if($item['obj']) {
$o = '<as:object>' . "\r\n";
- $r = json_decode($item['object'],false);
+ $r = json_decode($item['obj'],false);
if(! $r)
return '';
@@ -582,7 +582,7 @@ function get_atom_elements($feed, $item, &$author) {
$obj['content'] = $body;
}
- $res['object'] = $obj;
+ $res['obj'] = $obj;
}
$rawobj = $item->get_item_tags(NAMESPACE_ACTIVITY, 'target');
@@ -1163,12 +1163,12 @@ function atom_entry($item,$type,$author,$owner,$comment = false,$cid = 0) {
}
if(activity_match($item['obj_type'],ACTIVITY_OBJ_EVENT) && activity_match($item['verb'],ACTIVITY_POST)) {
- $obj = ((is_array($item['obj'])) ? $item['object'] : json_decode($item['object'],true));
+ $obj = ((is_array($item['obj'])) ? $item['obj'] : json_decode($item['obj'],true));
$o .= '<title>' . xmlify($item['title']) . '</title>' . "\r\n";
$o .= '<summary xmlns="urn:ietf:params:xml:ns:xcal">' . xmlify(bbcode($obj['title'])) . '</summary>' . "\r\n";
- $o .= '<dtstart xmlns="urn:ietf:params:xml:ns:xcal">' . datetime_convert('UTC','UTC', $obj['start'],'Ymd\\THis' . (($obj['adjust']) ? '\\Z' : '')) . '</dtstart>' . "\r\n";
- $o .= '<dtend xmlns="urn:ietf:params:xml:ns:xcal">' . datetime_convert('UTC','UTC', $obj['finish'],'Ymd\\THis' . (($obj['adjust']) ? '\\Z' : '')) . '</dtend>' . "\r\n";
+ $o .= '<dtstart xmlns="urn:ietf:params:xml:ns:xcal">' . datetime_convert('UTC','UTC', $obj['dtstart'],'Ymd\\THis' . (($obj['adjust']) ? '\\Z' : '')) . '</dtstart>' . "\r\n";
+ $o .= '<dtend xmlns="urn:ietf:params:xml:ns:xcal">' . datetime_convert('UTC','UTC', $obj['dtend'],'Ymd\\THis' . (($obj['adjust']) ? '\\Z' : '')) . '</dtend>' . "\r\n";
$o .= '<location xmlns="urn:ietf:params:xml:ns:xcal">' . xmlify(bbcode($obj['location'])) . '</location>' . "\r\n";
$o .= '<content type="' . $type . '" >' . xmlify(bbcode($obj['description'])) . '</content>' . "\r\n";
}