Skip to content

Commit e6af55d

Browse files
committed
fix: move the position of access token enable option
1 parent e5982ad commit e6af55d

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

internal/configs/version2/nginx-plus.virtualserver.tmpl

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -427,12 +427,9 @@ server {
427427
error_page 401 = @do_oidc_flow;
428428
auth_jwt_key_request /_jwks_uri;
429429
{{ $proxyOrGRPC }}_set_header username $jwt_claim_sub;
430-
{{ end }}
431-
432-
{{ with $oidc := $s.OIDC }}
433-
{{ if $oidc.AccessTokenEnable }}
430+
{{- if $s.OIDC.AccessTokenEnable }}
434431
{{ $proxyOrGRPC }}_set_header Authorization "Bearer $access_token";
435-
{{ end }}
432+
{{- end }}
436433
{{ end }}
437434

438435
{{ with $l.WAF }}

0 commit comments

Comments
 (0)