The repro steps are rather simple when you figure out what’s going on :
As an admin, change the min_first_post_length to something larger than 25
As a regular user, create a topic and delete it
You’d expect the topic to be closed and edited to say (topic deleted by author), but it will only get closed
What’s happening here is the (topic deleted by author) string is shorter than min_first_post_length and when the system edits the topic, the post length validations will not allow the edit to go through but the topic will be closed because it’s done separately.
My fix above bypasses all validations for the revision that the system makes when a user deletes their posts.