Description
At line 309, code performs type assertion without checking:
var cmdName = viper.Get(constants.ConfigKeyActiveCommand).(*cobra.Command).Name()
Multiple failure points: viper.Get() could return nil, value might not be *cobra.Command, or pointer could be nil.
Severity
LOW - Panic in logging code
Suggested Fix
Use safe type assertion with ok pattern.
Related Code
pkg/connection/refresh_connections_state.go:309