mirror of https://github.com/gofiber/fiber.git
✏️ Remove unused path parameter in README example (#1201)
* ✏️ Remove unused path parameter in example
* Update translations
pull/1206/head
parent
a179c6665c
commit
8e47ccd9ed
|
@ -153,7 +153,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -153,7 +153,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -150,7 +150,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -153,7 +153,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -206,7 +206,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -153,7 +153,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -156,7 +156,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -157,7 +157,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -157,7 +157,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -153,7 +153,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -153,7 +153,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -172,7 +172,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -151,7 +151,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -152,7 +152,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
|
@ -155,7 +155,7 @@ func main() {
|
|||
})
|
||||
|
||||
// GET /john/75
|
||||
app.Get("/:name/:age/:gender?", func(c *fiber.Ctx) error {
|
||||
app.Get("/:name/:age", func(c *fiber.Ctx) error {
|
||||
msg := fmt.Sprintf("👴 %s is %s years old", c.Params("name"), c.Params("age"))
|
||||
return c.SendString(msg) // => 👴 john is 75 years old
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue