Skip to content

Commit

Permalink
Merge pull request #4590 from influxdb/token_msg_on_cli_only
Browse files Browse the repository at this point in the history
Only display Enterprise hint on CLI mode
  • Loading branch information
otoolep committed Oct 28, 2015
2 parents 6311a2b + a727a8d commit 7278ec9
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions cmd/influx/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,16 +168,15 @@ Examples:
return
}

token, err := c.DatabaseToken()
if err != nil {
fmt.Fprintf(os.Stderr, "Failed to check token: %s\n", err.Error())
return
}
if token == "" {
fmt.Printf(noTokenMsg)
}

if c.Execute == "" && !c.Import {
token, err := c.DatabaseToken()
if err != nil {
fmt.Fprintf(os.Stderr, "Failed to check token: %s\n", err.Error())
return
}
if token == "" {
fmt.Printf(noTokenMsg)
}
fmt.Printf("Connected to %s version %s\n", c.Client.Addr(), c.Version)
}

Expand Down

0 comments on commit 7278ec9

Please sign in to comment.