mirror of
https://github.com/luthermonson/go-proxmox.git
synced 2026-04-26 01:15:57 +03:00
[PR #160] [MERGED] Fix return value of Clone functions when CloneOptions.NewID is set #186
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/go-proxmox#186
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/luthermonson/go-proxmox/pull/160
Author: @rybnico
Created: 9/5/2024
Status: ✅ Merged
Merged: 9/9/2024
Merged by: @luthermonson
Base:
main← Head:fix-vm-clone-return-value📝 Commits (2)
1f744c7Fix return value ofClonefunctions whenCloneOptions.NewIDis setfacd2e4Define named return value newid instead of returning params.NewID in clone functions📊 Changes
5 files changed (+64 additions, -3 deletions)
View changed files
📝
containers.go(+3 -1)📝
containers_test.go(+17 -1)📝
tests/mocks/pve7x/nodes.go(+6 -0)📝
virtual_machine.go(+2 -1)📝
virtual_machine_test.go(+36 -0)📄 Description
The
Clonefunctions (Container.CloneandVM.Clone), when called withCloneOptions.NewIDset, return 0 instead of theNewID.I extended the tests. Updated
TestContainerCloneand newTestVirtualMachineClonetests fail without this fix.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
api2/json/cluster/ceph/statusendpoint #203