[tools 2/2] testbot/web: Simplify action handling in the the Stats page.
Francois Gouget
fgouget at codeweavers.com
Thu Mar 10 05:00:52 CST 2022
The action is a no-op so unset it to not need to redefine OnAction().
Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
---
testbot/web/Stats.pl | 14 ++------------
1 file changed, 2 insertions(+), 12 deletions(-)
diff --git a/testbot/web/Stats.pl b/testbot/web/Stats.pl
index 42408a3a81..5ec69798f4 100644
--- a/testbot/web/Stats.pl
+++ b/testbot/web/Stats.pl
@@ -49,6 +49,8 @@ sub _initialize($$$)
$self->SetParam("Days", 7) if (!defined $self->{ErrMessage});
$self->{NoStats} = 1;
}
+ # The action is a no-op so unset it to not need to redefine OnAction()
+ $self->SetParam("Action", undef);
}
sub GetPageTitle($$)
@@ -367,18 +369,6 @@ sub GetActions($)
return ["Update"];
}
-sub OnAction($$)
-{
- my ($self, $Action) = @_;
-
- if ($Action eq "Update")
- {
- return $self->Validate() ? 1 : undef;
- }
-
- return $self->SUPER::OnAction($Action);
-}
-
sub GenerateFooter($)
{
my ($self) = @_;
--
2.30.2
More information about the wine-devel
mailing list