From 187ba9ffa239f0d2e6143feef052154e370d78ff Mon Sep 17 00:00:00 2001 From: Yaroslav Afenkin <91559310+yaroslavafenkin@users.noreply.github.com> Date: Fri, 15 Nov 2024 16:53:25 +0200 Subject: [PATCH] [JENKINS-74081] Migrate legacy `checkUrl` in `/ValidatingStringParameterDefinition/index.jelly` --- .../ValidatingStringParameterDefinition.java | 5 ++--- .../index.jelly | 17 ++++++++++------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/src/main/java/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition.java b/src/main/java/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition.java index a5e665e..ff3d5f3 100644 --- a/src/main/java/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition.java +++ b/src/main/java/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition.java @@ -116,9 +116,8 @@ public FormValidation doCheckRegex(@QueryParameter final String value) { * Called to validate the passed user entered value against the configured regular expression. */ @POST - public FormValidation doValidate(@QueryParameter("regex") String regex, - @QueryParameter("failedValidationMessage") final String failedValidationMessage, - @QueryParameter("value") final String value) { + public FormValidation doValidate(@QueryParameter String regex, @QueryParameter final String failedValidationMessage, + @QueryParameter final String value) { try { if (Pattern.matches(regex, value)) { return FormValidation.ok(); diff --git a/src/main/resources/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition/index.jelly b/src/main/resources/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition/index.jelly index 15a10ab..d5cc2fc 100644 --- a/src/main/resources/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition/index.jelly +++ b/src/main/resources/hudson/plugins/validating_string_parameter/ValidatingStringParameterDefinition/index.jelly @@ -25,12 +25,15 @@ THE SOFTWARE. - - -
- - -
+ + + + + + + + +