Skip to content

Remove redundant region parameters from API requests#284

Closed
alejandrojnm wants to merge 1 commit into
civo:masterfrom
alejandrojnm:fix/redundant-region-params
Closed

Remove redundant region parameters from API requests#284
alejandrojnm wants to merge 1 commit into
civo:masterfrom
alejandrojnm:fix/redundant-region-params

Conversation

@alejandrojnm

Copy link
Copy Markdown
Member

The client already handles adding the region parameter centrally in sendRequest() (client.go:206-213) for all HTTP methods. Removing these redundant region parameters from individual function calls:

  • instance.go: SetInstanceTags, UpdateInstance, GetInstanceVnc, HardRebootInstance, SoftRebootInstance, StopInstance, StartInstance, UpgradeInstance, SetInstanceFirewall
  • volume.go: ResizeVolume, DetachVolume
  • kubernetes.go: RecycleKubernetesCluster

Fixes #278

The client already handles adding the region parameter centrally in
sendRequest() (client.go:206-213) for all HTTP methods. Removing
these redundant region parameters from individual function calls:

- instance.go: SetInstanceTags, UpdateInstance, GetInstanceVnc,
  HardRebootInstance, SoftRebootInstance, StopInstance, StartInstance,
  UpgradeInstance, SetInstanceFirewall
- volume.go: ResizeVolume, DetachVolume
- kubernetes.go: RecycleKubernetesCluster

Fixes civo#278

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Redundant Region Parameters

1 participant