From 7078a03a3cb0fd9ca2109de29a4332e9a0930007 Mon Sep 17 00:00:00 2001 From: Hassan Date: Sun, 11 Feb 2024 16:28:44 +0500 Subject: [PATCH] fix: correct typo in the validate template for length restrictions --- internal/templates/rtp20022/validate.tgo | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/templates/rtp20022/validate.tgo b/internal/templates/rtp20022/validate.tgo index 2930cc4..28ee0a2 100644 --- a/internal/templates/rtp20022/validate.tgo +++ b/internal/templates/rtp20022/validate.tgo @@ -137,7 +137,7 @@ import ( } {{- end }} {{- if .Restriction.Length }} - if err := rtp.ValidateLength(string(v), {{ .Restriction.MinLength.Value }}); err != nil { + if err := rtp.ValidateLength(string(v), {{ .Restriction.Length.Value }}); err != nil { return err } {{- end }}