Fix instances of event.sender being read for just the userId - this field may not be set in time
This commit is contained in:
parent
376533e709
commit
b0053f36d3
4 changed files with 7 additions and 10 deletions
|
@ -401,7 +401,7 @@ export default class MessagePanel extends React.Component<IProps, IState> {
|
|||
|
||||
// TODO: Implement granular (per-room) hide options
|
||||
public shouldShowEvent(mxEv: MatrixEvent): boolean {
|
||||
if (mxEv.sender && MatrixClientPeg.get().isUserIgnored(mxEv.sender.userId)) {
|
||||
if (MatrixClientPeg.get().isUserIgnored(mxEv.getSender())) {
|
||||
return false; // ignored = no show (only happens if the ignore happens after an event was received)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue