We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cross posted from #2767
package main import "github.com/gin-gonic/gin" func main() { r := gin.Default() r.GET("/aa/:customer", newHandler("/aa/:customer")) r.GET("/aa/:customer/files/:file", newHandler("/aa/:customer/files/:file")) r.Run() } func newHandler(t string) func(c *gin.Context) { return func(c *gin.Context) { c.JSON(200, gin.H{ "message": t, }) } }
For the above code example, the request results are:
/aa/1/files/aa => /aa/:customer/files/:file /aa/1/files/ => /aa/:customer /aa/1/files => 404 /aa/1 => /aa/:customer
The text was updated successfully, but these errors were encountered:
See solution #2897 already merged in the master branch.
Sorry, something went wrong.
No branches or pull requests
Cross posted from #2767
For the above code example, the request results are:
The text was updated successfully, but these errors were encountered: