How to reproduce that:
- Create a REPLY in a topic (dont create a new topic).
- Soft delete this created reply.
- Delete pemanently this reply and wait for refresh.
It will go to another page and not for topic page.
If post were the last one in the topic, it will work fine.