Fix quote with CW but no text being shown without CW (#36150)

This commit is contained in:
Claire 2025-09-17 14:00:58 +02:00 committed by GitHub
parent 8a6ef2ebdf
commit 2664bb628b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -81,7 +81,7 @@ export function normalizeStatus(status, normalOldStatus) {
} else { } else {
// If the status has a CW but no contents, treat the CW as if it were the // If the status has a CW but no contents, treat the CW as if it were the
// status' contents, to avoid having a CW toggle with seemingly no effect. // status' contents, to avoid having a CW toggle with seemingly no effect.
if (normalStatus.spoiler_text && !normalStatus.content) { if (normalStatus.spoiler_text && !normalStatus.content && !normalStatus.quote) {
normalStatus.content = normalStatus.spoiler_text; normalStatus.content = normalStatus.spoiler_text;
normalStatus.spoiler_text = ''; normalStatus.spoiler_text = '';
} }