1
0
Fork 0
mirror of https://forgejo.ellis.link/continuwuation/continuwuity.git synced 2025-07-27 18:28:31 +00:00

fix: off by one.

This commit is contained in:
Jason Volk 2025-06-28 00:29:07 +00:00
parent 543ab27747
commit f508e7654c

View file

@ -722,7 +722,7 @@ impl Service {
if event_type != TimelineEventType::RoomCreate && prev_events.is_empty() {
return Err!(Request(Unknown("Event incorrectly had zero prev_events.")));
}
if state_key.is_none() && depth.le(&uint!(2)) {
if state_key.is_none() && depth.lt(&uint!(2)) {
// The first two events in a room are always m.room.create and m.room.member,
// so any other events with that same depth are illegal.
warn!(