pl-fe: set sensitive param correctly when editing a post

Signed-off-by: Nicole Mikołajczyk <git@mkljczk.pl>
This commit is contained in:
Nicole Mikołajczyk
2025-04-30 14:41:33 +02:00
parent f0048c741f
commit a28fe41e15
2 changed files with 2 additions and 1 deletions

View File

@ -118,7 +118,7 @@ const messages = defineMessages({
interface ComposeSetStatusAction {
type: typeof COMPOSE_SET_STATUS;
composeId: string;
status: Pick<Status, 'id' | 'account' | 'content' | 'group_id' | 'in_reply_to_id' | 'language' | 'media_attachments' | 'mentions' | 'quote_id' | 'spoiler_text' | 'visibility'>;
status: Pick<Status, 'id' | 'account' | 'content' | 'group_id' | 'in_reply_to_id' | 'language' | 'media_attachments' | 'mentions' | 'quote_id' | 'sensitive' | 'spoiler_text' | 'visibility'>;
poll?: Poll | null;
rawText: string;
explicitAddressing: boolean;

View File

@ -559,6 +559,7 @@ const compose = (state = initialState, action: ComposeAction | EventsAction | In
compose.language = action.status.language;
compose.media_attachments = action.status.media_attachments;
compose.sensitive = action.status.sensitive;
if (action.status.spoiler_text.length > 0) {
compose.spoiler_text = action.status.spoiler_text;