fix state handling in auth request

This commit is contained in:
Livio Amstutz 2020-09-15 08:06:18 +02:00
parent 3c2ad6a53d
commit 2dfdaa2223
2 changed files with 7 additions and 2 deletions

View file

@ -153,7 +153,11 @@ func (p *DefaultRP) AuthURL(state string, opts ...AuthURLOpt) string {
//AuthURL is the `RelayingParty` interface implementation
//extending the `AuthURL` method with a http redirect handler
func (p *DefaultRP) AuthURLHandler(state string) http.HandlerFunc {
return AuthURLHandler(state, p)
return AuthURLHandler(
func() string {
return state
}, p,
)
}
//deprecated: Use CodeExchange func and provide a RelayingParty