🐛 Fixup unmarshal to anonymous struct

This commit is contained in:
Ettore Di Giacinto 2022-10-17 22:27:39 +02:00 committed by GitHub
parent d9da1b4090
commit 06b8dc9c58
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,14 +52,14 @@ func getPass(server, label string) (string, error) {
func start() error {
factory := pluggable.NewPluginFactory()
connectionDetails := &struct {
connectionDetails := struct {
Server string `yaml:"challenger_server"`
}{}
var server string
d, err := machine.DotToYAML("/proc/cmdline")
if err == nil { // best-effort
yaml.Unmarshal(d, connectionDetails) //nolint:errcheck
yaml.Unmarshal(d, &connectionDetails) //nolint:errcheck
}
server = connectionDetails.Server
if os.Getenv("WSS_SERVER") != "" {