forked from forgejo/forgejo
* introduce GET /notifications/new * add TEST * use Sprintf instead of path.Join * Error more verbose * return number of notifications if unreaded exist * 200 http status for available notifications
This commit is contained in:
parent
ce274d652f
commit
44de66bf50
9 changed files with 107 additions and 5 deletions
|
@ -8,7 +8,6 @@ package models
|
|||
|
||||
import (
|
||||
"fmt"
|
||||
"path"
|
||||
"strings"
|
||||
|
||||
"code.gitea.io/gitea/modules/git"
|
||||
|
@ -249,7 +248,7 @@ func (c *Comment) APIURL() string {
|
|||
return ""
|
||||
}
|
||||
|
||||
return c.Issue.Repo.APIURL() + "/" + path.Join("issues/comments", fmt.Sprint(c.ID))
|
||||
return fmt.Sprintf("%s/issues/comments/%d", c.Issue.Repo.APIURL(), c.ID)
|
||||
}
|
||||
|
||||
// IssueURL formats a URL-string to the issue
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue