Update updateProductionTimers()
to handle Progress
value being undefined
This commit is contained in:
parent
37029791da
commit
d2f4327871
@ -233,6 +233,12 @@ export class HideoutHelper
|
||||
delete pmcData.Hideout.Production[prodId];
|
||||
}
|
||||
|
||||
if (craft.Progress === undefined)
|
||||
{
|
||||
this.logger.warning(`Craft ${prodId} has an undefined progress value, defaulting to 0`);
|
||||
craft.Progress = 0;
|
||||
}
|
||||
|
||||
// Craft complete, skip processing (Don't skip continious crafts like bitcoin farm)
|
||||
if (craft.Progress >= craft.ProductionTime && prodId !== HideoutHelper.bitcoinFarm)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user