1
0
forked from 0ad/0ad

fix division by zero for zero-time technologies. Fixes #2334

This was SVN commit r14459.
This commit is contained in:
sanderd17 2013-12-31 09:02:58 +00:00
parent c7ff0bb486
commit f8ca47913d

View File

@ -413,7 +413,7 @@ ProductionQueue.prototype.GetQueue = function()
"technologyTemplate": item.technologyTemplate,
"count": item.count,
"neededSlots": item.neededSlots,
"progress": 1-(item.timeRemaining/item.timeTotal),
"progress": 1 - ( item.timeRemaining / (item.timeTotal || 1) ),
"metadata": item.metadata,
});
}