From 654901d7dfe5c2a97d811facebc8718af81e7ce5 Mon Sep 17 00:00:00 2001 From: Jason Volk Date: Wed, 6 Mar 2019 14:09:54 -0800 Subject: [PATCH] modules/vm: Include empty auth_events array in create event rather than undefined. --- modules/vm.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/vm.cc b/modules/vm.cc index b345b234e..ec307849d 100644 --- a/modules/vm.cc +++ b/modules/vm.cc @@ -215,8 +215,8 @@ ircd::m::vm::eval__commit_room(eval &eval, }; char ae_buf[1024]; - json::array auth_events; - if(depth != -1 && opts.add_auth_events) + json::array auth_events{json::empty_array}; + if(depth != -1 && event.at("type") != "m.room.create" && opts.add_auth_events) { static const string_view types[] {