Skip to content

Commit 348c75c

Browse files
committed
issue: response wrong type of comment from AJAX
1 parent 76ebdb2 commit 348c75c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

routers/repo/issue.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -725,8 +725,8 @@ func UpdateIssueContent(ctx *context.Context) {
725725
return
726726
}
727727

728-
ctx.JSON(200, map[string]interface{}{
729-
"content": markup.Markdown(issue.Content, ctx.Query("context"), ctx.Repo.Repository.ComposeMetas()),
728+
ctx.JSON(200, map[string]string{
729+
"content": string(markup.Markdown(issue.Content, ctx.Query("context"), ctx.Repo.Repository.ComposeMetas())),
730730
})
731731
}
732732

@@ -936,8 +936,8 @@ func UpdateCommentContent(ctx *context.Context) {
936936
return
937937
}
938938

939-
ctx.JSON(200, map[string]interface{}{
940-
"content": markup.Markdown(comment.Content, ctx.Query("context"), ctx.Repo.Repository.ComposeMetas()),
939+
ctx.JSON(200, map[string]string{
940+
"content": string(markup.Markdown(comment.Content, ctx.Query("context"), ctx.Repo.Repository.ComposeMetas())),
941941
})
942942
}
943943

0 commit comments

Comments
 (0)