mirror of
https://mau.dev/mautrix/go.git
synced 2026-03-14 14:25:53 +01:00
bridgev2/commands: fix NPE on search
Signed-off-by: Sumner Evans <sumner.evans@automattic.com>
This commit is contained in:
parent
b68fdc9057
commit
7e7cb57ee7
1 changed files with 1 additions and 1 deletions
|
|
@ -181,7 +181,7 @@ func fnSearch(ce *Event) {
|
|||
ce.Log.Err(err).Object("portal_key", res.Chat.PortalKey).Msg("Failed to get DM portal")
|
||||
}
|
||||
}
|
||||
if res.Chat.Portal != nil {
|
||||
if res.Chat.Portal != nil && res.Chat.Portal.MXID != "" {
|
||||
portalName := res.Chat.Portal.Name
|
||||
if portalName == "" {
|
||||
portalName = res.Chat.Portal.MXID.String()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue