Negative open PR count persists

I have somehow been able to close a pull request twice, which results in an incorrect (negative) count of open pull request. This issue has supposedly been fixed in the code (Fix repository's pull request count error by lunny · Pull Request #7518 · go-gitea/gitea · GitHub), but after I upgraded to Gitea 1.16.5 and migrating the data, the incorrect negative count still shows. Will this be automatically fixed after opening or closing a new pull request, or should it have been corrected when migrating the database data? Or what do I need to do in order to correct this?