From 776020cc8a8ee6b189434b51813a6038855d04af Mon Sep 17 00:00:00 2001 From: Robin Ward Date: Fri, 12 Feb 2016 13:19:00 -0500 Subject: [PATCH] FIX: Wasn't jumping to new topic --- .../javascripts/discourse/controllers/composer.js.es6 | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/assets/javascripts/discourse/controllers/composer.js.es6 b/app/assets/javascripts/discourse/controllers/composer.js.es6 index 6031288a772..fa840dfcdc4 100644 --- a/app/assets/javascripts/discourse/controllers/composer.js.es6 +++ b/app/assets/javascripts/discourse/controllers/composer.js.es6 @@ -301,6 +301,14 @@ export default Ember.Controller.extend({ currentUser.set('reply_count', currentUser.get('reply_count') + 1); } + const disableJumpReply = Discourse.User.currentProp('disable_jump_reply'); + if (!composer.get('replyingToTopic') || !disableJumpReply) { + const post = result.target; + if (post && !staged) { + DiscourseURL.routeTo(post.get('url')); + } + } + }).catch(function(error) { composer.set('disableDrafts', false); self.appEvents.one('composer:opened', () => bootbox.alert(error));