Francois Gouget : testbot/cgi: Report all of a form's invalid fields at once.
Alexandre Julliard
julliard at winehq.org
Tue Jul 12 16:31:43 CDT 2022
Module: tools
Branch: master
Commit: ebb6e5bb15356e429c669f432fb1dc8b7e91e514
URL: https://gitlab.winehq.org/winehq/tools/-/commit/ebb6e5bb15356e429c669f432fb1dc8b7e91e514
Author: Francois Gouget <fgouget at codeweavers.com>
Date: Tue Jul 12 15:22:25 2022 +0200
testbot/cgi: Report all of a form's invalid fields at once.
Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
testbot/lib/ObjectModel/CGI/FormPage.pm | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/testbot/lib/ObjectModel/CGI/FormPage.pm b/testbot/lib/ObjectModel/CGI/FormPage.pm
index c299d54b..d6ded1b0 100644
--- a/testbot/lib/ObjectModel/CGI/FormPage.pm
+++ b/testbot/lib/ObjectModel/CGI/FormPage.pm
@@ -599,6 +599,7 @@ sub Validate($)
{
my ($self) = @_;
+ my $Ret = 1;
foreach my $PropertyDescriptor (@{$self->GetPropertyDescriptors()})
{
my $Value = $self->GetParam($PropertyDescriptor->GetName());
@@ -606,11 +607,11 @@ sub Validate($)
if ($ErrMessage)
{
$self->AddError($ErrMessage, $PropertyDescriptor->GetName());
- return !1;
+ $Ret = !1;
}
}
- return 1;
+ return $Ret;
}
sub SaveProperty($$$)
More information about the wine-cvs
mailing list