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

Function getAttachmentsByCommentID

internal/database/attachment.go:139–142  ·  view source on GitHub ↗
(e Engine, commentID int64)

Source from the content-addressed store, hash-verified

137}
138
139func getAttachmentsByCommentID(e Engine, commentID int64) ([]*Attachment, error) {
140 attachments := make([]*Attachment, 0, 5)
141 return attachments, e.Where("comment_id=?", commentID).Find(&attachments)
142}
143
144// GetAttachmentsByCommentID returns all attachments of a comment.
145func GetAttachmentsByCommentID(commentID int64) ([]*Attachment, error) {

Callers 2

loadAttributesMethod · 0.85

Calls 2

WhereMethod · 0.80
FindMethod · 0.65

Tested by

no test coverage detected