diff options
Diffstat (limited to 'models/issue_comment.go')
-rw-r--r-- | models/issue_comment.go | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/models/issue_comment.go b/models/issue_comment.go index 270a10e240..5c053ec02a 100644 --- a/models/issue_comment.go +++ b/models/issue_comment.go @@ -20,7 +20,6 @@ import ( "code.gitea.io/gitea/modules/markup/markdown" "code.gitea.io/gitea/modules/references" "code.gitea.io/gitea/modules/structs" - api "code.gitea.io/gitea/modules/structs" "code.gitea.io/gitea/modules/timeutil" "github.com/unknwon/com" @@ -354,20 +353,6 @@ func (c *Comment) PRURL() string { return c.Issue.HTMLURL() } -// APIFormat converts a Comment to the api.Comment format -func (c *Comment) APIFormat() *api.Comment { - return &api.Comment{ - ID: c.ID, - Poster: c.Poster.APIFormat(), - HTMLURL: c.HTMLURL(), - IssueURL: c.IssueURL(), - PRURL: c.PRURL(), - Body: c.Content, - Created: c.CreatedUnix.AsTime(), - Updated: c.UpdatedUnix.AsTime(), - } -} - // CommentHashTag returns unique hash tag for comment id. func CommentHashTag(id int64) string { return fmt.Sprintf("issuecomment-%d", id) |