0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-10-02 13:48:53 +02:00

ircd:Ⓜ️ Add developer convenience constructor to event_filter.

This commit is contained in:
Jason Volk 2018-04-19 13:47:51 -07:00
parent 328292ba0e
commit e57b85cb36
2 changed files with 11 additions and 0 deletions

View file

@ -36,6 +36,8 @@ struct ircd::m::event_filter
>
{
using super_type::tuple;
event_filter(const mutable_buffer &, const json::members &);
event_filter() = default;
using super_type::operator=;
};

View file

@ -156,3 +156,12 @@ ircd::m::filter::get(std::nothrow_t,
closure(content);
});
}
ircd::m::event_filter::event_filter(const mutable_buffer &buf,
const json::members &members)
:super_type::tuple
{
json::stringify(mutable_buffer{buf}, members)
}
{
}