FIX: Don't update the last read post when disable jump reply is set
This commit is contained in:
parent
b9df18360d
commit
baae2a4b7c
|
@ -413,18 +413,20 @@ class PostCreator
|
||||||
def track_topic
|
def track_topic
|
||||||
return if @opts[:auto_track] == false
|
return if @opts[:auto_track] == false
|
||||||
|
|
||||||
TopicUser.change(@post.user_id,
|
unless @user.user_option.disable_jump_reply?
|
||||||
@topic.id,
|
TopicUser.change(@post.user_id,
|
||||||
posted: true,
|
@topic.id,
|
||||||
last_read_post_number: @post.post_number,
|
posted: true,
|
||||||
highest_seen_post_number: @post.post_number)
|
last_read_post_number: @post.post_number,
|
||||||
|
highest_seen_post_number: @post.post_number)
|
||||||
|
|
||||||
|
|
||||||
# assume it took us 5 seconds of reading time to make a post
|
# assume it took us 5 seconds of reading time to make a post
|
||||||
PostTiming.record_timing(topic_id: @post.topic_id,
|
PostTiming.record_timing(topic_id: @post.topic_id,
|
||||||
user_id: @post.user_id,
|
user_id: @post.user_id,
|
||||||
post_number: @post.post_number,
|
post_number: @post.post_number,
|
||||||
msecs: 5000)
|
msecs: 5000)
|
||||||
|
end
|
||||||
|
|
||||||
if @user.staged
|
if @user.staged
|
||||||
TopicUser.auto_watch(@user.id, @topic.id)
|
TopicUser.auto_watch(@user.id, @topic.id)
|
||||||
|
|
Loading…
Reference in New Issue