删除主题后,删除按钮显示而不是恢复按钮

This issue sort of prevents users from restoring a topic they deleted.

Repro steps:

  1. Create a topic

  2. Delete the topic → You’re automatically redirected to the topic list

  3. Click the now-closed topic

  4. Click the button to show the restore button

  5. There is no restore button, the delete button is shown instead

    • If you click once on the delete button, the topic remains closed, and you’re redirected back to the topic list after being briefly shown the restore button during the loading
    • If you manage to click the restore button during the short time it is visible, then the topic is properly restored (despite being shown as closed after the redirection, and it will be shown as not closed after reloading the topic list)

In the video, I first delete the topic, it works properly.
Then I open it again, click the delete button, and swiftly click the restore button, so the topic is restored.

I don’t know if the issue occurs for moderators and admins.