forked from forgejo/forgejo
Rewrite XORM queries
This commit is contained in:
parent
c040f2fbb1
commit
a4454f5d0f
22 changed files with 480 additions and 233 deletions
|
@ -356,7 +356,9 @@ func GetCommentByID(id int64) (*Comment, error) {
|
|||
|
||||
func getCommentsByIssueIDSince(e Engine, issueID, since int64) ([]*Comment, error) {
|
||||
comments := make([]*Comment, 0, 10)
|
||||
sess := e.Where("issue_id = ?", issueID).Asc("created_unix")
|
||||
sess := e.
|
||||
Where("issue_id = ?", issueID).
|
||||
Asc("created_unix")
|
||||
if since > 0 {
|
||||
sess.And("updated_unix >= ?", since)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue