mirror of
https://github.com/discourse/discourse.git
synced 2025-06-01 01:24:48 +08:00
Revert "FIX: Topic Timer auto opening closed topics (#10524)"
This reverts commit 7cfd5f87ff16d3010274851b7442aa92c2d494d6.
This commit is contained in:
@ -127,6 +127,7 @@ class TopicTimer < ActiveRecord::Base
|
||||
|
||||
def schedule_auto_open_job(time)
|
||||
return unless topic
|
||||
topic.update_status('closed', true, user) if !topic.closed
|
||||
|
||||
Jobs.enqueue_at(time, :toggle_topic_closed,
|
||||
topic_timer_id: id,
|
||||
@ -136,6 +137,7 @@ class TopicTimer < ActiveRecord::Base
|
||||
|
||||
def schedule_auto_close_job(time)
|
||||
return unless topic
|
||||
topic.update_status('closed', false, user) if topic.closed
|
||||
|
||||
Jobs.enqueue_at(time, :toggle_topic_closed,
|
||||
topic_timer_id: id,
|
||||
|
Reference in New Issue
Block a user