From 40af440cce32864f00b4c64dd1e0f2208bfe6bfe Mon Sep 17 00:00:00 2001 From: Pavel Boldyrev <627562+bpg@users.noreply.github.com> Date: Fri, 5 Jul 2024 08:51:43 -0400 Subject: [PATCH] fix some linter errors Signed-off-by: Pavel Boldyrev <627562+bpg@users.noreply.github.com> --- fwprovider/vm/cloudinit/model.go | 1 + proxmox/nodes/vms/custom_storage_device.go | 1 + 2 files changed, 2 insertions(+) diff --git a/fwprovider/vm/cloudinit/model.go b/fwprovider/vm/cloudinit/model.go index 4713c494..bebb0ec8 100644 --- a/fwprovider/vm/cloudinit/model.go +++ b/fwprovider/vm/cloudinit/model.go @@ -18,6 +18,7 @@ type Model struct { DNS DNSValue `tfsdk:"dns"` } +// ModelDNS represents the DNS model of the Cloud-Init. type ModelDNS struct { Domain types.String `tfsdk:"domain"` Servers types.List `tfsdk:"servers"` diff --git a/proxmox/nodes/vms/custom_storage_device.go b/proxmox/nodes/vms/custom_storage_device.go index ce56d64b..927fb47f 100644 --- a/proxmox/nodes/vms/custom_storage_device.go +++ b/proxmox/nodes/vms/custom_storage_device.go @@ -81,6 +81,7 @@ func (d *CustomStorageDevice) PathInDatastore() *string { return &pathInDatastore } +// GetDatastoreID returns datastore ID part of FileVolume or empty string if it is not yet allocated. func (d *CustomStorageDevice) GetDatastoreID() string { if datastoreID, _, found := strings.Cut(d.FileVolume, ":"); found { return datastoreID