diff options
author | 2023-11-27 14:00:57 +0000 | |
---|---|---|
committer | 2023-11-27 14:00:57 +0000 | |
commit | 74700cc8034980334e7df466f313287a41d2b8a6 (patch) | |
tree | 63ab8912c813eefba8a492e0d0489f4e5fe59446 /internal/api/client/markers | |
parent | [chore]: Bump codeberg.org/gruf/go-mutexes from 1.3.0 to 1.3.1 (#2387) (diff) | |
download | gotosocial-74700cc8034980334e7df466f313287a41d2b8a6.tar.xz |
[performance] http response encoding / writing improvements (#2374)
Diffstat (limited to 'internal/api/client/markers')
-rw-r--r-- | internal/api/client/markers/markersget.go | 2 | ||||
-rw-r--r-- | internal/api/client/markers/markerspost.go | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/internal/api/client/markers/markersget.go b/internal/api/client/markers/markersget.go index eb403dcc6..9f4fc4270 100644 --- a/internal/api/client/markers/markersget.go +++ b/internal/api/client/markers/markersget.go @@ -84,7 +84,7 @@ func (m *Module) MarkersGETHandler(c *gin.Context) { return } - c.JSON(http.StatusOK, marker) + apiutil.JSON(c, http.StatusOK, marker) } // parseMarkerNames turns a list of strings into a set of valid marker timeline names, or returns an error. diff --git a/internal/api/client/markers/markerspost.go b/internal/api/client/markers/markerspost.go index 3167becac..8fe40c798 100644 --- a/internal/api/client/markers/markerspost.go +++ b/internal/api/client/markers/markerspost.go @@ -106,5 +106,5 @@ func (m *Module) MarkersPOSTHandler(c *gin.Context) { return } - c.JSON(http.StatusOK, marker) + apiutil.JSON(c, http.StatusOK, marker) } |