Skip to content
New issue

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

refactor: use gin.IRouter instead of gin.Engine #42

Merged
merged 1 commit into from
May 5, 2024

Conversation

Laisky
Copy link
Contributor

@Laisky Laisky commented Nov 2, 2023

I thinks it would be better for developer to use gin.IRouter interface than gin.Engine.

gin.Engine is the root router for server. However, there are situations where only the sub-routes obtained after multiple calls to .Group are passed in the code, that is gin.IRouter. In such cases, it becomes difficult to bind pprof.

- Change parameter type of `Register` function to `gin.IRouter`
- Fix typo in comment in `pprof.go`
- Omitted large changes in files diff summary
@appleboy appleboy merged commit 7b5b3bc into gin-contrib:master May 5, 2024
@appleboy
Copy link
Member

appleboy commented May 5, 2024

@Laisky Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants