summaryrefslogtreecommitdiff
path: root/vendor/github.com/gin-gonic/gin/render
diff options
context:
space:
mode:
authorLibravatar Daenney <daenney@users.noreply.github.com>2023-02-25 13:12:40 +0100
committerLibravatar GitHub <noreply@github.com>2023-02-25 12:12:40 +0000
commitecdc8379fa8f9d88faca626e7de748c2afbe4910 (patch)
tree8c20a5826db2136fc89bee45e15355c5899fa65b /vendor/github.com/gin-gonic/gin/render
parent[bugfix] Fix deleted status causing issues when getting bookmark (#1551) (diff)
downloadgotosocial-ecdc8379fa8f9d88faca626e7de748c2afbe4910.tar.xz
[chore] Update gin to v1.9.0 (#1553)
Diffstat (limited to 'vendor/github.com/gin-gonic/gin/render')
-rw-r--r--vendor/github.com/gin-gonic/gin/render/json.go7
-rw-r--r--vendor/github.com/gin-gonic/gin/render/yaml.go2
2 files changed, 3 insertions, 6 deletions
diff --git a/vendor/github.com/gin-gonic/gin/render/json.go b/vendor/github.com/gin-gonic/gin/render/json.go
index af678e80d..fc8dea453 100644
--- a/vendor/github.com/gin-gonic/gin/render/json.go
+++ b/vendor/github.com/gin-gonic/gin/render/json.go
@@ -53,11 +53,8 @@ var (
)
// Render (JSON) writes data with custom ContentType.
-func (r JSON) Render(w http.ResponseWriter) (err error) {
- if err = WriteJSON(w, r.Data); err != nil {
- panic(err)
- }
- return
+func (r JSON) Render(w http.ResponseWriter) error {
+ return WriteJSON(w, r.Data)
}
// WriteContentType (JSON) writes JSON ContentType.
diff --git a/vendor/github.com/gin-gonic/gin/render/yaml.go b/vendor/github.com/gin-gonic/gin/render/yaml.go
index 4f0ac01f6..fc927c1f2 100644
--- a/vendor/github.com/gin-gonic/gin/render/yaml.go
+++ b/vendor/github.com/gin-gonic/gin/render/yaml.go
@@ -7,7 +7,7 @@ package render
import (
"net/http"
- "gopkg.in/yaml.v2"
+ "gopkg.in/yaml.v3"
)
// YAML contains the given interface object.