Browse Source

Merge pull request #7801 from heyitsanthony/s1027

*: clear redundant return statement warnings (S1027)
Anthony Romano 8 năm trước cách đây
mục cha
commit
a73950545a
4 tập tin đã thay đổi với 0 bổ sung5 xóa
  1. 0 1
      integration/cluster.go
  2. 0 1
      mvcc/key_index.go
  3. 0 2
      pkg/schedule/schedule.go
  4. 0 1
      store/node.go

+ 0 - 1
integration/cluster.go

@@ -340,7 +340,6 @@ func (c *cluster) waitMembersMatch(t *testing.T, membs []client.Member) {
 			time.Sleep(tickDuration)
 		}
 	}
-	return
 }
 
 func (c *cluster) WaitLeader(t *testing.T) int { return c.waitLeader(t, c.Members) }

+ 0 - 1
mvcc/key_index.go

@@ -222,7 +222,6 @@ func (ki *keyIndex) compact(atRev int64, available map[revision]struct{}) {
 	}
 	// remove the previous generations.
 	ki.generations = ki.generations[i:]
-	return
 }
 
 func (ki *keyIndex) isEmpty() bool {

+ 0 - 2
pkg/schedule/schedule.go

@@ -88,8 +88,6 @@ func (f *fifo) Schedule(j Job) {
 		}
 	}
 	f.pendings = append(f.pendings, j)
-
-	return
 }
 
 func (f *fifo) Pending() int {

+ 0 - 1
store/node.go

@@ -332,7 +332,6 @@ func (n *node) UpdateTTL(expireTime time.Time) {
 	n.ExpireTime = expireTime
 	// push into ttl heap
 	n.store.ttlKeyHeap.push(n)
-	return
 }
 
 // Compare function compares node index and value with provided ones.