Why is there no record of who added or removed slow mode?

Slow mode is very useful for some topics on our forum. But I found Discourse has a serious design flaw about it: there is no record of who added or removed slow mode. I even checked the database and there’s still no record. Any TL4 users have this ability. For controversial topics, adding or removing slow mode makes the topic even more controversial and we really need to know which user did it.

1 Like

You can query this information using Data Explorer. I think this should work - you’ll need to specify start and end dates. It should return the topic, the slow mode time in seconds, when the topic slow mode was updated, and who did it:

-- [params]
-- date :start_date
-- date :end_date

SELECT 
    t.id AS topic_id,
    t.title,
    t.slow_mode_seconds,
    t.updated_at,
    u.id AS user_id,
    u.username
FROM 
    topics t
JOIN 
    users u ON t.user_id = u.id
WHERE 
    t.slow_mode_seconds > 0
    AND t.updated_at BETWEEN :start_date AND :end_date
ORDER BY 
    t.updated_at DESC
2 Likes

I think they’re stored in topic_timers (at least while they’re active) so something like this could probably do the trick:

SELECT 
    topic_id,
    user_id
FROM topic_timers
WHERE status_type = 9

Though in both queries it only gives the active timers and not the results where the slow mode has ended. I think it would be a good addition to have this for the staff action logs.

5 Likes

This gives me the user who created (or last updated) the topic, not the user who added or removed slow mode.

1 Like

What’s important for us is who removed the slow mode which is added by the admin.

Agree

2 Likes

hah yes I can see that now. :thinking:

u.id AS user_id,

Hello @physixfan

Thanks your suggestion! This is indeed a useful feature request. I have merged the PR that adds this functionality:

You can now see who has modified slow mode in the admin logs panel:

8 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.