Previously, all posters were updated, even if they were not part of
posterMaps. In that case, a ghost user was erroneously inserted.
Fixes #31213.
}
for _, comment := range comments {
- comment.Poster = getPoster(comment.PosterID, posterMaps)
+ if comment.Poster == nil {
+ comment.Poster = getPoster(comment.PosterID, posterMaps)
+ }
}
return nil
}
}
for _, issue := range issues {
- issue.Poster = getPoster(issue.PosterID, posterMaps)
+ if issue.Poster == nil {
+ issue.Poster = getPoster(issue.PosterID, posterMaps)
+ }
}
return nil
}