(e Engine, issueID, since int64)
| 432 | } |
| 433 | |
| 434 | func getCommentsByIssueIDSince(e Engine, issueID, since int64) ([]*Comment, error) { |
| 435 | comments := make([]*Comment, 0, 10) |
| 436 | sess := e.Where("issue_id = ?", issueID).Asc("created_unix") |
| 437 | if since > 0 { |
| 438 | sess.And("updated_unix >= ?", since) |
| 439 | } |
| 440 | |
| 441 | if err := sess.Find(&comments); err != nil { |
| 442 | return nil, err |
| 443 | } |
| 444 | return comments, loadCommentsAttributes(e, comments) |
| 445 | } |
| 446 | |
| 447 | func getCommentsByRepoIDSince(e Engine, repoID, since int64) ([]*Comment, error) { |
| 448 | comments := make([]*Comment, 0, 10) |
no test coverage detected