From: Isabelle Knott Date: Thu, 13 Apr 2017 01:17:34 +0000 (-0400) Subject: Clear spoiler when replying to toot that doesn't also have a spoiler (#1662) X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=96715d9af5a95d75b244efc67c6870325c2b322d;p=mastodon.git Clear spoiler when replying to toot that doesn't also have a spoiler (#1662) --- diff --git a/app/assets/javascripts/components/reducers/compose.jsx b/app/assets/javascripts/components/reducers/compose.jsx index 00cc758a5..86974239b 100644 --- a/app/assets/javascripts/components/reducers/compose.jsx +++ b/app/assets/javascripts/components/reducers/compose.jsx @@ -157,6 +157,9 @@ export default function compose(state = initialState, action) { if (action.status.get('spoiler_text').length > 0) { map.set('spoiler', true); map.set('spoiler_text', action.status.get('spoiler_text')); + } else { + map.set('spoiler', false); + map.set('spoiler_text', ''); } }); case COMPOSE_REPLY_CANCEL: