Yeah, I confirm it.
The problem is in this condition:
https://github.com/mybb/mybb/blob/featur...d.php#L927
There should be another condition to check if usergroup can see deleted posts. And when you go to a thread and there is action=lastpost in the query, it should only go to the last active post.
The problem is in this condition:
https://github.com/mybb/mybb/blob/featur...d.php#L927
if(empty($post) || ($post['visible'] == 0 && !is_moderator($post['fid'], 'canviewunapprove')) || ($post['visible'] == -1 && !is_moderator($post['fid'], 'canviewdeleted')))
There should be another condition to check if usergroup can see deleted posts. And when you go to a thread and there is action=lastpost in the query, it should only go to the last active post.