From: Thibaut Girka Date: Fri, 1 Feb 2019 11:45:53 +0000 (+0100) Subject: Do not mark toots as sensitive if they don't have any media attached X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=f611da489929d2592b61b0c0f7c870ae33782343;p=mastodon.git Do not mark toots as sensitive if they don't have any media attached --- diff --git a/app/javascript/flavours/glitch/actions/compose.js b/app/javascript/flavours/glitch/actions/compose.js index 71d3fb1b2..04e857713 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']), }, {