diff --git a/interfaces.go b/interfaces.go index 9d0481e3c..a5c5bb5ba 100644 --- a/interfaces.go +++ b/interfaces.go @@ -177,9 +177,9 @@ type LinodeInstanceInterfaceCreateOptions struct { } type LinodeInterfaceUpdateOptions struct { - DefaultRoute *InterfaceDefaultRoute `json:"default_route,omitempty"` - Public *PublicInterfaceCreateOptions `json:"public,omitempty"` - VPC *VPCInterfaceUpdateOptions `json:"vpc,omitempty"` + DefaultRoute *InterfaceDefaultRouteUpdateOptions `json:"default_route,omitzero"` + Public *PublicInterfaceCreateOptions `json:"public,omitzero"` + VPC *VPCInterfaceUpdateOptions `json:"vpc,omitzero"` // NOTE: RDMA VPC interfaces may not currently be available to all users. RDMAVPC *RDMAVPCInterfaceUpdateOptions `json:"rdma_vpc,omitzero"` diff --git a/test/unit/rdma_vpc_test.go b/test/unit/rdma_vpc_test.go index 5c4ee5ca9..befa46c5e 100644 --- a/test/unit/rdma_vpc_test.go +++ b/test/unit/rdma_vpc_test.go @@ -6,7 +6,7 @@ import ( "testing" "github.com/jarcoal/httpmock" - "github.com/linode/linodego" + "github.com/linode/linodego/v2" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) @@ -294,7 +294,7 @@ func TestInstance_CreateWithLinodeInterfaces_BackwardsCompatible(t *testing.T) { VPC: &linodego.VPCInterfaceCreateOptions{ SubnetID: 4, IPv4: &linodego.VPCInterfaceIPv4CreateOptions{ - Addresses: &[]linodego.VPCInterfaceIPv4AddressCreateOptions{ + Addresses: []linodego.VPCInterfaceIPv4AddressCreateOptions{ { Address: linodego.Pointer("10.0.0.5"), Primary: linodego.Pointer(true), diff --git a/vpc.go b/vpc.go index ff2e62e2e..42812fdf1 100644 --- a/vpc.go +++ b/vpc.go @@ -63,7 +63,7 @@ type VPCCreateOptions struct { Label string `json:"label"` Description string `json:"description,omitzero"` Region string `json:"region"` - + // This field is omitted by the API for customers that do not have // access to the GPUDirect RDMA functionality. // NOTE: RDMA VPCs may not currently be available to all users.