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

Simplify RedirectHandler #13

Open
g105b opened this issue Aug 6, 2022 · 0 comments
Open

Simplify RedirectHandler #13

g105b opened this issue Aug 6, 2022 · 0 comments

Comments

@g105b
Copy link
Member

g105b commented Aug 6, 2022

RedirectHandler should construct with a nullable callback function. If it's not supplied, then continue using the header() call by default, otherwise call the callback.

This will allow passing in the Gt\Http\Response's redirect function, like this:

new Authenticator(
	$this->config->getString("authwave.api_key"),
	$serverInfo->getRequestUri(),
	$this->config->getString("authwave.host"),
	$awSession,
	$response->redirect(...),
);
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