Fix NPE on null display name

This commit is contained in:
Andrew
2024-03-12 11:32:47 +10:30
parent e68290b572
commit 3cba05e668
2 changed files with 5 additions and 10 deletions

View File

@@ -182,7 +182,7 @@ open class Storage(
}
override fun getUserProfile(): Profile {
val displayName = TextSecurePreferences.getProfileName(context)!!
val displayName = TextSecurePreferences.getProfileName(context)
val profileKey = ProfileKeyUtil.getProfileKey(context)
val profilePictureUrl = TextSecurePreferences.getProfilePictureURL(context)
return Profile(displayName, profileKey, profilePictureUrl)