[PATCH] testbot/web: Tweak VMsList::OnItemAction() to save the Item directly.

Francois Gouget fgouget at codeweavers.com
Mon Mar 26 20:45:37 CDT 2018


OnItemAction() is called on each selected Item and should only operate
on the specified Item rather than blindly saving all the Items in the
Collection.

Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
---
 testbot/web/admin/VMsList.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testbot/web/admin/VMsList.pl b/testbot/web/admin/VMsList.pl
index 652fc8e1b..500442b5b 100644
--- a/testbot/web/admin/VMsList.pl
+++ b/testbot/web/admin/VMsList.pl
@@ -58,7 +58,7 @@ sub OnItemAction($$$$)
   if ($Action eq "Delete")
   {
     $Item->Role("deleted");
-    my ($ErrKey, $ErrProperty, $ErrMessage) = $self->{Collection}->Save();
+    my ($ErrProperty, $ErrMessage) = $Item->Save();
     return ! defined($ErrMessage);
   }
 
-- 
2.16.2



More information about the wine-devel mailing list