diff --git a/vector/src/main/java/im/vector/riotx/features/notifications/NotificationDrawerManager.kt b/vector/src/main/java/im/vector/riotx/features/notifications/NotificationDrawerManager.kt index 763aea5e..97d3a67c 100644 --- a/vector/src/main/java/im/vector/riotx/features/notifications/NotificationDrawerManager.kt +++ b/vector/src/main/java/im/vector/riotx/features/notifications/NotificationDrawerManager.kt @@ -182,7 +182,8 @@ class NotificationDrawerManager @Inject constructor(private val context: Context private fun refreshNotificationDrawerBg() { Timber.w("refreshNotificationDrawerBg()") - val session = activeSessionHolder.getActiveSession() + val session = activeSessionHolder.getSafeActiveSession() ?: return + val user = session.getUser(session.sessionParams.credentials.userId) val myUserDisplayName = user?.displayName ?: session.sessionParams.credentials.userId val myUserAvatarUrl = session.contentUrlResolver().resolveThumbnail(user?.avatarUrl, avatarSize, avatarSize, ContentUrlResolver.ThumbnailMethod.SCALE)