DEV: Avoid repeating draft key logic in multiple places.

This commit is contained in:
Guo Xiang Tan
2020-05-12 11:13:18 +08:00
parent a009ec597d
commit 3c423faafd
2 changed files with 3 additions and 4 deletions

View File

@ -301,9 +301,8 @@ describe PostCreator do
end
it 'creates post stats' do
Draft.set(user, 'new_topic', 0, "test")
Draft.set(user, 'new_topic', 0, "test1")
Draft.set(user, Draft::NEW_TOPIC, 0, "test")
Draft.set(user, Draft::NEW_TOPIC, 0, "test1")
begin
PostCreator.track_post_stats = true