mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-10-29 14:42:24 -05:00
[performance] http response encoding / writing improvements (#2374)
This commit is contained in:
parent
d7e35f6bc9
commit
74700cc803
104 changed files with 526 additions and 267 deletions
|
|
@ -107,5 +107,5 @@ func (m *Module) ReportPOSTHandler(c *gin.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
c.JSON(http.StatusOK, apiReport)
|
||||
apiutil.JSON(c, http.StatusOK, apiReport)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -90,5 +90,5 @@ func (m *Module) ReportGETHandler(c *gin.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
c.JSON(http.StatusOK, report)
|
||||
apiutil.JSON(c, http.StatusOK, report)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -168,5 +168,6 @@ func (m *Module) ReportsGETHandler(c *gin.Context) {
|
|||
if resp.LinkHeader != "" {
|
||||
c.Header("Link", resp.LinkHeader)
|
||||
}
|
||||
c.JSON(http.StatusOK, resp.Items)
|
||||
|
||||
apiutil.JSON(c, http.StatusOK, resp.Items)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue