A platform for community discussion. Free, open, simple.
FIX: Queued Posts were not saving tags properly
Robin Ward8181ad646bda
diff --git a/lib/new_post_manager.rb b/lib/new_post_manager.rbindex c99abea3542..b5de841f9ba 100644--- a/lib/new_post_manager.rb+++ b/lib/new_post_manager.rb@@ -183,7 +183,7 @@ class NewPostManagerreviewable = ReviewableQueuedPost.new(created_by: @user,- payload: { raw: @args[:raw] },+ payload: { raw: @args[:raw], tags: @args[:tags] },topic_id: @args[:topic_id],reviewable_by_moderator: true)diff --git a/spec/components/new_post_manager_spec.rb b/spec/components/new_post_manager_spec.rbindex bc35f00730c..b00def4e333 100644--- a/spec/components/new_post_manager_spec.rb+++ b/spec/components/new_post_manager_spec.rb@@ -268,7 +268,8 @@ describe NewPostManager domanager = NewPostManager.new(topic.user,raw: 'to the handler I say enqueue me!',- title: 'this is the title of the queued post'+ title: 'this is the title of the queued post',+ tags: ['hello', 'world'])result = manager.perform@@ -280,6 +281,7 @@ describe NewPostManager doexpect(reviewable.reviewable_scores).to be_presentexpect(reviewable.score).to eq(20.5)expect(reviewable.reviewable_by_moderator?).to eq(true)+ expect(reviewable.payload['tags']).to eq(['hello', 'world'])expect(result.action).to eq(:enqueued)expect(result).to be_successexpect(result.pending_count).to eq(1)