Fix delete user missed some comments (#21067)
There is a mistake in the batched delete comments part of DeleteUser which causes some comments to not be deleted The code incorrectly updates the `start` of the limit clause resulting in most comments not being deleted. ```go if err = e.Where("type=? AND poster_id=?", issues_model.CommentTypeComment, u.ID).Limit(batchSize, start).Find(&comments); err != nil { ``` should be: ```go if err = e.Where("type=? AND poster_id=?", issues_model.CommentTypeComment, u.ID).Limit(batchSize, 0).Find(&comments); err != nil { ``` Co-authored-by: zeripath <art27@cantab.net>tokarchuk/v1.18
parent
b42aaf29ea
commit
bc4cce138a
Loading…
Reference in new issue