Skip to content

Commit 34a3955

Browse files
author
Christian Paul
authored
MatrixEvent.getRoomId can return undefined (#2036)
1 parent 8212287 commit 34a3955

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/models/event.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -437,10 +437,10 @@ export class MatrixEvent extends EventEmitter {
437437
/**
438438
* Get the room_id for this event. This will return <code>undefined</code>
439439
* for <code>m.presence</code> events.
440-
* @return {string} The room ID, e.g. <code>!cURbafjkfsMDVwdRDQ:matrix.org
440+
* @return {string?} The room ID, e.g. <code>!cURbafjkfsMDVwdRDQ:matrix.org
441441
* </code>
442442
*/
443-
public getRoomId(): string {
443+
public getRoomId(): string | undefined {
444444
return this.event.room_id;
445445
}
446446

0 commit comments

Comments
 (0)