From 916e05bc24878e5461f3a0bac87e732359eaee70 Mon Sep 17 00:00:00 2001 From: Aditya Manthramurthy Date: Tue, 13 Jun 2023 13:49:33 -0700 Subject: [PATCH] Fix unconfigured IDP output in `idp info` command (#4600) --- cmd/idp-openid-subcommands.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cmd/idp-openid-subcommands.go b/cmd/idp-openid-subcommands.go index 8c595af6..0876f175 100644 --- a/cmd/idp-openid-subcommands.go +++ b/cmd/idp-openid-subcommands.go @@ -412,6 +412,10 @@ func (i idpConfig) JSON() string { } func (i idpConfig) String() string { + if len(i.Info) == 0 { + return "Not configured." + } + // Determine required width for key column. fieldColWidth := 0 for _, kv := range i.Info {