diff options
author | Friendika <info@friendika.com> | 2011-02-01 16:50:19 -0800 |
---|---|---|
committer | Friendika <info@friendika.com> | 2011-02-01 16:50:19 -0800 |
commit | 6a4ae2e845f6f9897574833ced287a3a316119b0 (patch) | |
tree | f048b6e8e9547e7c8f2e093ebae3ea8c7f6399c6 /include | |
parent | 8c5c07b2654f5ff28cea1a7012198f74c5b1af03 (diff) | |
download | volse-hubzilla-6a4ae2e845f6f9897574833ced287a3a316119b0.tar.gz volse-hubzilla-6a4ae2e845f6f9897574833ced287a3a316119b0.tar.bz2 volse-hubzilla-6a4ae2e845f6f9897574833ced287a3a316119b0.zip |
get correct article timestamp for feeds with no 'published' and with non-utc stamps
Diffstat (limited to 'include')
-rw-r--r-- | include/items.php | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/include/items.php b/include/items.php index 5747d301d..ebb7b7af0 100644 --- a/include/items.php +++ b/include/items.php @@ -455,14 +455,16 @@ function get_atom_elements($feed,$item) { $rawedited = $item->get_item_tags(SIMPLEPIE_NAMESPACE_ATOM_10,'updated'); if($rawedited) - $res['edited'] = unxmlify($rawcreated[0]['data']); + $res['edited'] = unxmlify($rawedited[0]['data']); + if((x($res,'edited')) && (! (x($res,'created')))) + $res['created = $res['edited']; if(! $res['created']) - $res['created'] = $item->get_date(); + $res['created'] = $item->get_date('c'); if(! $res['edited']) - $res['edited'] = $item->get_date(); + $res['edited'] = $item->get_date('c'); $rawowner = $item->get_item_tags(NAMESPACE_DFRN, 'owner'); |