diff --git a/models/issue.go b/models/issue.go index 3bd45396dcf2..d10c521db6d8 100644 --- a/models/issue.go +++ b/models/issue.go @@ -248,7 +248,7 @@ func (issue *Issue) GetIsRead(userID int64) error { // APIURL returns the absolute APIURL to this issue. func (issue *Issue) APIURL() string { - return issue.Repo.APIURL() + "/" + path.Join("issues", fmt.Sprint(issue.ID)) + return issue.Repo.APIURL() + "/" + path.Join("issues", fmt.Sprint(issue.Index)) } // HTMLURL returns the absolute URL to this issue.