Skip to content

Commit 6b31c0c

Browse files
committed
Use fwvalidators.ARN()
1 parent a4d6b1b commit 6b31c0c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/service/pinpointsmsvoicev2/phone_number.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ import (
3535
"github.com/hashicorp/terraform-provider-aws/internal/framework"
3636
fwflex "github.com/hashicorp/terraform-provider-aws/internal/framework/flex"
3737
fwtypes "github.com/hashicorp/terraform-provider-aws/internal/framework/types"
38+
fwvalidators "github.com/hashicorp/terraform-provider-aws/internal/framework/validators"
3839
tftags "github.com/hashicorp/terraform-provider-aws/internal/tags"
3940
"github.com/hashicorp/terraform-provider-aws/internal/tfresource"
4041
"github.com/hashicorp/terraform-provider-aws/names"
@@ -134,7 +135,7 @@ func (r *phoneNumberResource) Schema(ctx context.Context, request resource.Schem
134135
path.MatchRelative().AtParent().AtName("two_way_channel_enabled"),
135136
),
136137
stringvalidator.Any(
137-
stringvalidator.RegexMatches(regexache.MustCompile(`^arn`), "must be a valid ARN"),
138+
fwvalidators.ARN(),
138139
stringvalidator.RegexMatches(regexache.MustCompile(`^connect\.[a-z0-9-]+\.amazonaws.com$`), "Must be connect.{region}.amazonaws.com"),
139140
),
140141
},

0 commit comments

Comments
 (0)