The issue: the last page doesn't open if the error and duplicate posts are at the beginning of that page.
My solution:
1. I delete some posts from the second-to-last page until it becomes the last page.
2. I clean up the duplicates, leaving only one copy.
3. I restore the deleted messages (when deleting, I mark them as "this is good, I'll restore it later").
4. ???
5. This actually works.
6. PROFIT in the form of moderator activity points :3
🏹🎪+⛓️♿=💕