Skip to content

Commit

Permalink
fix various errors
Browse files Browse the repository at this point in the history
  • Loading branch information
0pcom committed Jul 13, 2024
1 parent e9e0cf6 commit 5f1330b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions cmd/skywire-cli/commands/survey/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ import (

"github.com/skycoin/dmsg/pkg/disc"
"github.com/skycoin/dmsg/pkg/dmsg"
"github.com/skycoin/skycoin/src/cipher"
"github.com/spf13/cobra"

"github.com/skycoin/skywire-utilities/pkg/cipher"
"github.com/skycoin/skywire-utilities/pkg/cmdutil"
"github.com/skycoin/skywire-utilities/pkg/logging"
"github.com/skycoin/skywire-utilities/pkg/skyenv"
Expand Down Expand Up @@ -81,10 +81,10 @@ var surveyCmd = &cobra.Command{
log.WithError(err).Fatal("Failed to unmarshal old config json")
}
}
if conf != nil {
dmsgDisc = conf.Dmsg.Discovery
}
survey, err := visorconfig.SystemSurvey(dmsgDisc)
// if conf != nil {
// dmsgDisc = conf.Dmsg.Discovery
// }
survey, err := visorconfig.SystemSurvey()

Check failure on line 87 in cmd/skywire-cli/commands/survey/root.go

View workflow job for this annotation

GitHub Actions / darwin

not enough arguments in call to visorconfig.SystemSurvey

Check failure on line 87 in cmd/skywire-cli/commands/survey/root.go

View workflow job for this annotation

GitHub Actions / darwin

not enough arguments in call to visorconfig.SystemSurvey

Check failure on line 87 in cmd/skywire-cli/commands/survey/root.go

View workflow job for this annotation

GitHub Actions / windows

not enough arguments in call to visorconfig.SystemSurvey
if err != nil {
internal.Catch(cmd.Flags(), fmt.Errorf("Failed to generate system survey: %v", err))
}
Expand All @@ -106,10 +106,10 @@ var surveyCmd = &cobra.Command{
survey.ServicesURLs.StunServers = conf.StunServers
//survey.DmsgServers = v.dmsgC.ConnectedServersPK()
}
if dmsgdisc != "" {
ipAddr, err = FetchIP(dmsgDisc)
if dmsgDisc != "" {
ipAddr, err := FetchIP(dmsgDisc)
if err == nil {
survey.IPAddr = ipAddr.String()
survey.IPAddr = ipAddr
}
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/visor/survey.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func GenerateSurvey(v *Visor, log *logging.Logger, routine bool) {
log.Info("Skycoin reward address: ", cAddr.String())
//generate the system survey
pathutil.EnsureDir(v.conf.LocalPath) //nolint
survey, err := visconf.SystemSurvey(v.conf.Dmsg.Discovery)
survey, err := visconf.SystemSurvey()

Check failure on line 36 in pkg/visor/survey.go

View workflow job for this annotation

GitHub Actions / darwin

not enough arguments in call to visconf.SystemSurvey

Check failure on line 36 in pkg/visor/survey.go

View workflow job for this annotation

GitHub Actions / darwin

not enough arguments in call to visconf.SystemSurvey

Check failure on line 36 in pkg/visor/survey.go

View workflow job for this annotation

GitHub Actions / darwin

not enough arguments in call to visconf.SystemSurvey

Check failure on line 36 in pkg/visor/survey.go

View workflow job for this annotation

GitHub Actions / darwin

not enough arguments in call to visconf.SystemSurvey

Check failure on line 36 in pkg/visor/survey.go

View workflow job for this annotation

GitHub Actions / windows

not enough arguments in call to visconf.SystemSurvey
if err != nil {
log.WithError(err).Error("Could not read system info.")
return
Expand Down

0 comments on commit 5f1330b

Please sign in to comment.