0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-12-26 15:33:54 +01:00

ircd:Ⓜ️:event::conforms: Update event_id related conditions.

This commit is contained in:
Jason Volk 2019-07-08 18:57:45 -07:00
parent d37aaa8542
commit aa78f6f85c
2 changed files with 5 additions and 2 deletions

View file

@ -701,6 +701,10 @@ ircd::m::event::conforms::conforms(const event &e,
ircd::m::event::conforms::conforms(const event &e)
:report{0}
{
if(!e.event_id)
set(INVALID_OR_MISSING_EVENT_ID);
if(defined(json::get<"event_id"_>(e)))
if(!valid(m::id::EVENT, json::get<"event_id"_>(e)))
set(INVALID_OR_MISSING_EVENT_ID);

View file

@ -175,7 +175,6 @@ put__invite(client &client,
m::event::conforms non_conforms;
non_conforms |= non_conforms.MISSING_PREV_STATE;
non_conforms |= non_conforms.INVALID_OR_MISSING_EVENT_ID;
const m::event::conforms report
{
event, non_conforms.report