fix: fix slice init length

This commit is contained in:
cui fliter 2024-10-04 19:32:27 +08:00 committed by GitHub
parent 61c3bb887b
commit c7d24a5d3f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -121,7 +121,7 @@ func (a *AuthRequest) Done() bool {
}
func PromptToInternal(oidcPrompt oidc.SpaceDelimitedArray) []string {
prompts := make([]string, len(oidcPrompt))
prompts := make([]string, 0, len(oidcPrompt))
for _, oidcPrompt := range oidcPrompt {
switch oidcPrompt {
case oidc.PromptNone,