From e37aab29672256218d30876e96dd17fedc0506f7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0imon=20Brandner?= Date: Fri, 7 Oct 2022 16:40:40 +0200 Subject: [PATCH] Fix `power_level_content_override` type (#2741) --- src/@types/requests.ts | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/@types/requests.ts b/src/@types/requests.ts index 9d0472cee1a..4246cbab6f8 100644 --- a/src/@types/requests.ts +++ b/src/@types/requests.ts @@ -22,7 +22,7 @@ import { IRoomEventFilter } from "../filter"; import { Direction } from "../models/event-timeline"; import { PushRuleAction } from "./PushRules"; import { IRoomEvent } from "../sync-accumulator"; -import { RoomType } from "./event"; +import { EventType, RoomType } from "./event"; // allow camelcase as these are things that go onto the wire /* eslint-disable camelcase */ @@ -98,7 +98,18 @@ export interface ICreateRoomOpts { name?: string; topic?: string; preset?: Preset; - power_level_content_override?: object; + power_level_content_override?: { + ban?: number; + events?: Record; + events_default?: number; + invite?: number; + kick?: number; + notifications?: Record; + redact?: number; + state_default?: number; + users?: Record; + users_default?: number; + }; creation_content?: object; initial_state?: ICreateRoomStateEvent[]; invite?: string[];