CA-364152: Do not calculate completed percentage if there are no actions to run.

Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
This commit is contained in:
Konstantina Chremmou 2022-02-21 21:52:16 +00:00
parent a578b6924c
commit a342adc859

View File

@ -175,6 +175,9 @@ namespace XenAdmin.Actions
protected override void RecalculatePercentComplete() protected override void RecalculatePercentComplete()
{ {
if (actionsCount == 0)
return;
int total = 0; int total = 0;
foreach (IXenConnection connection in actionsByConnection.Keys) foreach (IXenConnection connection in actionsByConnection.Keys)
{ {