set notice titles in RSS and Atom output

This commit is contained in:
Evan Prodromou 2010-08-13 11:50:33 -07:00
parent ed8d8eb5ee
commit 96705b4ec5

View File

@ -162,5 +162,27 @@ class NoticeTitlePlugin extends Plugin
return true;
}
function onEndRssEntryArray($notice, &$entry)
{
$title = Notice_title::fromNotice($notice);
if (!empty($title)) {
$entry['title'] = $title;
}
return true;
}
function onStartActivityTitle(&$notice, &$xs, &$output)
{
$title = Notice_title::fromNotice($notice);
if (!empty($title)) {
$output = $title;
}
return true;
}
}