mirror of
https://github.com/gin-gonic/gin.git
synced 2025-10-23 18:22:23 +08:00
fix 200 to http.Status
This commit is contained in:
parent
81007d2ce0
commit
5a2b38cf0f
@ -13,10 +13,10 @@ func init() {
|
||||
|
||||
// Define your handlers
|
||||
r.GET("/", func(c *gin.Context) {
|
||||
c.String(200, "Hello World!")
|
||||
c.String(http.StatusOK, "Hello World!")
|
||||
})
|
||||
r.GET("/ping", func(c *gin.Context) {
|
||||
c.String(200, "pong")
|
||||
c.String(http.StatusOK, "pong")
|
||||
})
|
||||
|
||||
// Handle all requests using net/http
|
||||
|
Loading…
x
Reference in New Issue
Block a user