From f611da489929d2592b61b0c0f7c870ae33782343 Mon Sep 17 00:00:00 2001 From: Thibaut Girka Date: Fri, 1 Feb 2019 12:45:53 +0100 Subject: [PATCH] Do not mark toots as sensitive if they don't have any media attached --- app/javascript/flavours/glitch/actions/compose.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/flavours/glitch/actions/compose.js b/app/javascript/flavours/glitch/actions/compose.js index 71d3fb1b23..04e8577132 100644 --- a/app/javascript/flavours/glitch/actions/compose.js +++ b/app/javascript/flavours/glitch/actions/compose.js @@ -134,7 +134,7 @@ export function submitCompose(routerHistory) { status, in_reply_to_id: getState().getIn(['compose', 'in_reply_to'], null), media_ids: media.map(item => item.get('id')), - sensitive: getState().getIn(['compose', 'sensitive']) || spoilerText.length > 0, + sensitive: getState().getIn(['compose', 'sensitive']) || (spoilerText.length > 0 && media.size !== 0), spoiler_text: spoilerText, visibility: getState().getIn(['compose', 'privacy']), }, {