mirror of
https://github.com/discourse/discourse.git
synced 2025-06-01 01:14:29 +08:00
FEATURE: Skip small actions when counting replies in PMs. (#7108)
This commit is contained in:
@ -248,7 +248,11 @@ class PostCreator
|
||||
post.word_count = post.raw.scan(/[[:word:]]+/).size
|
||||
|
||||
whisper = post.post_type == Post.types[:whisper]
|
||||
post.post_number ||= Topic.next_post_number(post.topic_id, post.reply_to_post_number.present?, whisper)
|
||||
increase_posts_count = !post.topic&.private_message? || post.post_type != Post.types[:small_action]
|
||||
post.post_number ||= Topic.next_post_number(post.topic_id,
|
||||
reply: post.reply_to_post_number.present?,
|
||||
whisper: whisper,
|
||||
post: increase_posts_count)
|
||||
|
||||
cooking_options = post.cooking_options || {}
|
||||
cooking_options[:topic_id] = post.topic_id
|
||||
|
Reference in New Issue
Block a user