mirror of
https://github.com/matrix-construct/construct
synced 2024-11-29 18:22:50 +01:00
modules/vm: Better conditions for room_id iov append.
This commit is contained in:
parent
2f71edf41f
commit
6f7949eb2c
1 changed files with 8 additions and 2 deletions
|
@ -351,9 +351,15 @@ ircd::m::vm::inject(eval &eval,
|
|||
};
|
||||
|
||||
assert(eval.room_id);
|
||||
const json::iov::push room_id
|
||||
const json::iov::add room_id_
|
||||
{
|
||||
event, { "room_id", eval.room_id }
|
||||
event, eval.room_id && !event.has("room_id"),
|
||||
{
|
||||
"room_id", [&eval]() -> json::value
|
||||
{
|
||||
return eval.room_id;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
const json::iov::add origin_
|
||||
|
|
Loading…
Reference in a new issue