1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-11-26 17:03:12 +03:00

getStateEvent should return any (#2032)

* getStateEvent returns any

getStateEvent returns the content of an event, not the whole state event as per https://matrix.org/docs/spec/client_server/r0.6.0#get-matrix-client-r0-rooms-roomid-state-eventtype-statekey

* Make the return type Record<string, any>

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
Will Hunt
2021-11-23 13:54:54 +00:00
committed by GitHub
parent 67b8da719f
commit 9f97992196

View File

@@ -6613,7 +6613,7 @@ export class MatrixClient extends EventEmitter {
eventType: string,
stateKey: string,
callback?: Callback,
): Promise<IStateEventWithRoomId> {
): Promise<Record<string, any>> {
const pathParams = {
$roomId: roomId,
$eventType: eventType,