FEATURE: Automatically timed delete stub topics after entire topic is merged into another topic (PR #13187)

In the past, we were only closing fully merged topics. Now we start setting a timer for deletion on them. By default, stub topics will be deleted in 7 days. Users can change this period or disable this feature by setting the period to 0.

GitHub

Setting name suggestion: delete_merged_stub_topics_after_days - using “after” instead of “before”, and placing the units (days) at the end, which is the style we’ve chosen.

The following should be a little bit more efficient.

            timer = topic.topic_timers.find_by(status_type: TopicTimer.types[:delete])

Looks good, but I think there should be a negativ test to ensure no topic timer is created when the setting is enabled and not all posts are moved.

Looks good, but I think there should be a negativ test to ensure no topic timer is created when the setting is enabled and not all posts are moved.

An excellent suggestion :+1:

I’ve applied this in a separate commit.

And the name will be shorter, I’ve renamed the setting.