Skip to content

Commit

Permalink
fix: remove pointer to worker (#12)
Browse files Browse the repository at this point in the history
* fix: remove pointer to worker

* fix: skip publish flag
  • Loading branch information
ilya-hontarau authored Jul 19, 2024
1 parent c2ceb3b commit 1413709
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ jobs:
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: --skip-publish --snapshot
args: --skip=publish --snapshot
6 changes: 3 additions & 3 deletions internal/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ type State struct {
ASG *types.AutoScalingGroup

inServiceInstanceIDs map[InstanceID]struct{}
workersByInstanceID map[InstanceID]*Worker
workersByInstanceID map[InstanceID]Worker
}

func NewState(workerPool *WorkerPool, asg *types.AutoScalingGroup) (*State, error) {
workersByInstanceID := make(map[InstanceID]*Worker)
workersByInstanceID := make(map[InstanceID]Worker)
inServiceInstanceIDs := make(map[InstanceID]struct{})

// Validate the ASG.
Expand Down Expand Up @@ -49,7 +49,7 @@ func NewState(workerPool *WorkerPool, asg *types.AutoScalingGroup) (*State, erro
return nil, fmt.Errorf("incorrect worker ASG: %s", groupID)
}

workersByInstanceID[instanceID] = &worker
workersByInstanceID[instanceID] = worker
}

for _, instance := range asg.Instances {
Expand Down

0 comments on commit 1413709

Please sign in to comment.