From 42c32359299c1066268052e553c40b43e2c3b845 Mon Sep 17 00:00:00 2001 From: Weiwei Li Date: Fri, 1 Nov 2024 12:40:41 -0700 Subject: [PATCH] Fix: order must match specified subnets --- pkg/networking/subnet_resolver.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/networking/subnet_resolver.go b/pkg/networking/subnet_resolver.go index aba7fba31..f00e8a51d 100644 --- a/pkg/networking/subnet_resolver.go +++ b/pkg/networking/subnet_resolver.go @@ -3,10 +3,11 @@ package networking import ( "context" "fmt" - ec2types "github.com/aws/aws-sdk-go-v2/service/ec2/types" "sort" "strings" + ec2types "github.com/aws/aws-sdk-go-v2/service/ec2/types" + awssdk "github.com/aws/aws-sdk-go-v2/aws" ec2sdk "github.com/aws/aws-sdk-go-v2/service/ec2" "github.com/go-logr/logr" @@ -328,7 +329,6 @@ func (r *defaultSubnetsResolver) ResolveViaNameOrIDSlice(ctx context.Context, su if err := r.validateSubnetsMinimalCount(resolvedSubnets, subnetLocale, resolveOpts); err != nil { return nil, err } - sortSubnetsByID(resolvedSubnets) return resolvedSubnets, nil }