File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -221,7 +221,9 @@ This is useful when working with multiple organizations or environments.`,
221221 if len (accounts ) == 1 {
222222 // Only one account, just confirm it's active
223223 for accountName := range accounts {
224- cfg .SetActiveAccount (accountName )
224+ if err := cfg .SetActiveAccount (accountName ); err != nil {
225+ return fmt .Errorf ("failed to set active account: %w" , err )
226+ }
225227 if err := config .SaveConfig (cfg ); err != nil {
226228 return fmt .Errorf ("failed to save config: %w" , err )
227229 }
@@ -249,7 +251,9 @@ This is useful when working with multiple organizations or environments.`,
249251 fmt .Println ()
250252 }
251253 fmt .Print ("\n Enter account name to switch to: " )
252- fmt .Scanln (& targetAccount )
254+ if _ , err := fmt .Scanln (& targetAccount ); err != nil {
255+ return fmt .Errorf ("failed to read input: %w" , err )
256+ }
253257 }
254258
255259 if targetAccount == "" {
You can’t perform that action at this time.
0 commit comments