mirror of
https://github.com/discourse/discourse.git
synced 2026-08-12 05:55:39 -05:00
DEV: Simplify client and server side code to support removing tags.
Follow up to 834c86678f.
This commit is contained in:
@@ -677,14 +677,6 @@ describe PostRevisor do
|
||||
expect(post.topic.tags.size).to eq(0)
|
||||
end
|
||||
|
||||
it "can remove all tags using tags_empty_array" do
|
||||
topic.tags = [Fabricate(:tag, name: "stuff")]
|
||||
result = subject.revise!(user, raw: "lets totally update the body", tags_empty_array: "true")
|
||||
expect(result).to eq(true)
|
||||
post.reload
|
||||
expect(post.topic.tags.size).to eq(0)
|
||||
end
|
||||
|
||||
it "can't add staff-only tags" do
|
||||
create_staff_tags(['important'])
|
||||
result = subject.revise!(user, raw: "lets totally update the body", tags: ['important', 'stuff'])
|
||||
|
||||
Reference in New Issue
Block a user