Browse Source

Merge pull request #729 from unihorn/65

chore: gofmt go files
Yicheng Qin 11 years ago
parent
commit
63d965133f
2 changed files with 1 additions and 2 deletions
  1. 1 1
      server/peer_server.go
  2. 0 1
      tests/functional/discovery_test.go

+ 1 - 1
server/peer_server.go

@@ -366,7 +366,7 @@ func (s *PeerServer) startAsFollower(cluster []string, retryTimes int) error {
 		if ok {
 			break
 		}
-		if i == retryTimes - 1 {
+		if i == retryTimes-1 {
 			return fmt.Errorf("Cannot join the cluster via given peers after %x retries", s.Config.RetryTimes)
 		}
 		log.Warnf("%v is unable to join the cluster using any of the peers %v at %dth time. Retrying in %.1f seconds", s.Config.Name, cluster, i, s.Config.RetryInterval)

+ 0 - 1
tests/functional/discovery_test.go

@@ -347,7 +347,6 @@ func TestDiscoveryRestart(t *testing.T) {
 	})
 }
 
-
 func assertServerNotUp(client http.Client, scheme string) error {
 	path := fmt.Sprintf("%s://127.0.0.1:4001/v2/keys/foo", scheme)
 	fields := url.Values(map[string][]string{"value": {"bar"}})