You've already forked matrix-js-sdk
mirror of
https://github.com/matrix-org/matrix-js-sdk.git
synced 2025-11-25 05:23:13 +03:00
MatrixEvent.getRoomId can return undefined (#2036)
This commit is contained in:
@@ -437,10 +437,10 @@ export class MatrixEvent extends EventEmitter {
|
|||||||
/**
|
/**
|
||||||
* Get the room_id for this event. This will return <code>undefined</code>
|
* Get the room_id for this event. This will return <code>undefined</code>
|
||||||
* for <code>m.presence</code> events.
|
* for <code>m.presence</code> events.
|
||||||
* @return {string} The room ID, e.g. <code>!cURbafjkfsMDVwdRDQ:matrix.org
|
* @return {string?} The room ID, e.g. <code>!cURbafjkfsMDVwdRDQ:matrix.org
|
||||||
* </code>
|
* </code>
|
||||||
*/
|
*/
|
||||||
public getRoomId(): string {
|
public getRoomId(): string | undefined {
|
||||||
return this.event.room_id;
|
return this.event.room_id;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user