Manage redirect URL from admin and save in hydra via pusher (#1492)
Add redirect parameter url to connect user directly on private openId application Signed-off-by: Gregoire Parant <g.parant@thecodingmachine.com>
This commit is contained in:
parent
4650f4e8cf
commit
1e69bb0f49
3 changed files with 10 additions and 5 deletions
|
@ -28,7 +28,7 @@ export class AuthenticateController extends BaseController {
|
|||
});
|
||||
|
||||
try {
|
||||
const { nonce, state, playUri } = parse(req.getQuery());
|
||||
const { nonce, state, playUri, redirect } = parse(req.getQuery());
|
||||
if (!state || !nonce) {
|
||||
throw "missing state and nonce URL parameters";
|
||||
}
|
||||
|
@ -36,7 +36,8 @@ export class AuthenticateController extends BaseController {
|
|||
const loginUri = await openIDClient.authorizationUrl(
|
||||
state as string,
|
||||
nonce as string,
|
||||
playUri as string | undefined
|
||||
playUri as string | undefined,
|
||||
redirect as string | undefined
|
||||
);
|
||||
res.writeStatus("302");
|
||||
res.writeHeader("Location", loginUri);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue