MCPcopy Create free account
hub / github.com/gogs/gogs / loadCommentsAttributes

Function loadCommentsAttributes

internal/database/comment.go:424–432  ·  view source on GitHub ↗

FIXME: use CommentList to improve performance.

(e Engine, comments []*Comment)

Source from the content-addressed store, hash-verified

422
423// FIXME: use CommentList to improve performance.
424func loadCommentsAttributes(e Engine, comments []*Comment) (err error) {
425 for i := range comments {
426 if err = comments[i].loadAttributes(e); err != nil {
427 return errors.Newf("loadAttributes [%d]: %v", comments[i].ID, err)
428 }
429 }
430
431 return nil
432}
433
434func getCommentsByIssueIDSince(e Engine, issueID, since int64) ([]*Comment, error) {
435 comments := make([]*Comment, 0, 10)

Callers 2

getCommentsByRepoIDSinceFunction · 0.85

Calls 1

loadAttributesMethod · 0.45

Tested by

no test coverage detected