Skip to content

Commit

Permalink
refactor: support AbortWithStatusJSON (#200)
Browse files Browse the repository at this point in the history
  • Loading branch information
appleboy authored Mar 29, 2017
1 parent d94c943 commit 5b2b369
Show file tree
Hide file tree
Showing 67 changed files with 55,187 additions and 127 deletions.
3 changes: 1 addition & 2 deletions gorush/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,10 @@ func init() {
}

func abortWithError(c *gin.Context, code int, message string) {
c.JSON(code, gin.H{
c.AbortWithStatusJSON(code, gin.H{
"code": code,
"message": message,
})
c.Abort()
}

func rootHandler(c *gin.Context) {
Expand Down
6 changes: 2 additions & 4 deletions vendor/github.com/gin-gonic/gin/AUTHORS.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion vendor/github.com/gin-gonic/gin/BENCHMARKS.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 5b2b369

Please sign in to comment.