[tools 2/2] testbot/web: Simplify the Log page Download action handling.
Francois Gouget
fgouget at codeweavers.com
Thu Mar 10 05:00:42 CST 2022
The action is pretty simple so there is no need for a separate function.
Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
---
testbot/web/admin/Log.pl | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
diff --git a/testbot/web/admin/Log.pl b/testbot/web/admin/Log.pl
index f8e4943b3d..ddc655f6d6 100644
--- a/testbot/web/admin/Log.pl
+++ b/testbot/web/admin/Log.pl
@@ -65,18 +65,14 @@ sub GetActions($)
return ["Download"];
}
-sub OnDownload($)
-{
- my ($self) = @_;
-
- exit($self->Redirect("/admin/SendLog.pl?Hours=". $self->GetParam("Hours")));
-}
-
sub OnAction($$)
{
my ($self, $Action) = @_;
- return $self->OnDownload() if ($Action eq "Download");
+ if ($Action eq "Download")
+ {
+ exit($self->Redirect("/admin/SendLog.pl?Hours=". $self->GetParam("Hours")));
+ }
return $self->SUPER::OnAction($Action);
}
--
2.30.2
More information about the wine-devel
mailing list