diff --git a/include/ircd/m/room/messages.h b/include/ircd/m/room/messages.h index 999194690..b9a5b5575 100644 --- a/include/ircd/m/room/messages.h +++ b/include/ircd/m/room/messages.h @@ -57,6 +57,8 @@ struct ircd::m::room::messages uint64_t depth() const; // Available from the iterator key. string_view state_root() const; // Available from the iterator value. + explicit operator event::idx() const; + const m::event &fetch(std::nothrow_t); const m::event &fetch(); diff --git a/ircd/m_room.cc b/ircd/m_room.cc index fcb17ad1e..372518d96 100644 --- a/ircd/m_room.cc +++ b/ircd/m_room.cc @@ -1781,6 +1781,13 @@ catch(const db::not_found &e) return false; } +ircd::m::room::messages::operator +ircd::m::event::idx() +const +{ + return event_idx(); +} + ircd::m::event::id::buf ircd::m::room::messages::event_id() const