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

Can we change the cores handler to a non-anonymous function? #48

Open
mnhkahn opened this issue Jan 6, 2019 · 0 comments
Open

Can we change the cores handler to a non-anonymous function? #48

mnhkahn opened this issue Jan 6, 2019 · 0 comments

Comments

@mnhkahn
Copy link

mnhkahn commented Jan 6, 2019

We used gin and this cores package. I found a problem that the cores handler is a anonymous
handler, and this causes a problem that we use the function's to auto statistic api's cost time. Cores handler will show func1, so I'm considering if we can change the function like this:

func New(config Config) gin.HandlerFunc {
	cors := newCors(config)
	return cors.applyCors(c)
}
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

No branches or pull requests

1 participant