go-gitea:main
← realaravinth:forgefriends-mr-31
opened 08:28AM - 03 Jan 22 UTC
> On behalf of [Loïc Dachary](https://lab.forgefriends.org/dachary)
They were… previously not covered at all, either by integration tests
or unit tests.
https://app.codecov.io/gh/go-gitea/gitea/blob/main/models/migrate.go
It fixes a bug where the `num_comments` field was incorrectly set to include all types of comments.
It also sets num_closed_issues: 0 as default in milestone fixtures. If they are not set, Incr("num_closed_issues") will be a noop because the field is null.
The would be the case for instance in models/migrate.go
[xorm] [info] 2021/12/30 21:38:05.370805 [SQL] UPDATE `milestone` SET `num_issues` = `num_issues` + ?, `num_closed_issues`
---
source: https://lab.forgefriends.org/forgefriends/forgefriends/-/merge_requests/31