Skip to content

Commit cf577b2

Browse files
committed
Fix more problems
1 parent fc1888b commit cf577b2

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

cmd/sync/aws.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -198,13 +198,13 @@ func (client *AWSClient) getInstancesInService(insIDtoIP map[string]string) ([]s
198198
const maxItems = 50
199199
var result []string
200200
keys := reflect.ValueOf(insIDtoIP).MapKeys()
201-
instanceIds := make([]string, len(keys))
201+
instanceIDs := make([]string, len(keys))
202202

203203
for i := 0; i < len(keys); i++ {
204-
instanceIds[i] = keys[i].String()
204+
instanceIDs[i] = keys[i].String()
205205
}
206206

207-
batches := prepareBatches(maxItems, instanceIds)
207+
batches := prepareBatches(maxItems, instanceIDs)
208208
for _, batch := range batches {
209209
params := &autoscaling.DescribeAutoScalingInstancesInput{
210210
InstanceIds: batch,

cmd/sync/aws_test.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -167,11 +167,11 @@ func areEqualUpstreamsAWS(u1 awsUpstream, u2 Upstream) bool {
167167
func TestPrepareBatches(t *testing.T) {
168168
const maxItems = 3
169169
ids := []string{"i-394ujfs", "i-dfdinf", "i-fsfsf", "i-8hr83hfwif", "i-nsnsnan"}
170-
instanceIds := make([]string, len(ids))
170+
instanceIDs := make([]string, len(ids))
171171

172-
copy(instanceIds, ids)
172+
copy(instanceIDs, ids)
173173

174-
batches := prepareBatches(maxItems, instanceIds)
174+
batches := prepareBatches(maxItems, instanceIDs)
175175

176176
if len(batches) > len(ids)/maxItems+1 {
177177
t.Error("prepareBatches() didn't split the slice correctly")

0 commit comments

Comments
 (0)