mirror of
https://github.com/mastodon/mastodon-ios.git
synced 2025-01-05 13:27:36 +01:00
fix: content warning label set when spoiler text is empty issue
This commit is contained in:
parent
4d2e75f3ca
commit
7e625f74d2
@ -98,6 +98,7 @@ extension StatusSection {
|
||||
let isStatusTextSensitive = statusContentWarningAttribute?.isStatusTextSensitive ?? (toot.reblog ?? toot).sensitive
|
||||
cell.statusView.updateContentWarningDisplay(isHidden: !isStatusTextSensitive)
|
||||
cell.statusView.contentWarningTitle.text = (toot.reblog ?? toot).spoilerText.flatMap { spoilerText in
|
||||
guard !spoilerText.isEmpty else { return nil }
|
||||
return L10n.Common.Controls.Status.contentWarning + ": \(spoilerText)"
|
||||
} ?? L10n.Common.Controls.Status.contentWarning
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user