We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit 638d29a8 authored by Evan Prodromou's avatar Evan Prodromou

Hide RSVPs from threaded notice output

parent b80ece16
......@@ -488,4 +488,18 @@ class EventPlugin extends MicroappPlugin
$action->cssLink($this->path('event.css'));
return true;
}
function onStartShowThreadedNoticeTail($nli, $notice, &$children)
{
// Filter out any poll responses
if ($notice->object_type == Happening::OBJECT_TYPE) {
$children = array_filter($children, array($this, 'isNotRSVP'));
}
return true;
}
function isNotRSVP($notice)
{
return (!in_array($notice->object_type, array(RSVP::POSITIVE, RSVP::NEGATIVE, RSVP::POSSIBLE)));
}
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment