Change warning in checkTraderRepairValuesExist() to use nickname

This commit is contained in:
Dev 2023-11-10 10:37:26 +00:00
parent c4c923f8dc
commit ade4875362

View File

@ -240,7 +240,7 @@ export class GameController
const trader = this.databaseServer.getTables().traders[traderKey]; const trader = this.databaseServer.getTables().traders[traderKey];
if (!trader?.base?.repair) if (!trader?.base?.repair)
{ {
this.logger.warning(`Trader ${trader.base._id} ${trader.base.name} is missing a repair object, adding in default values`); this.logger.warning(`Trader ${trader.base._id} ${trader.base.nickname} is missing a repair object, adding in default values`);
trader.base.repair = this.jsonUtil.clone(this.databaseServer.getTables().traders.ragfair.base.repair); trader.base.repair = this.jsonUtil.clone(this.databaseServer.getTables().traders.ragfair.base.repair);
return; return;
@ -248,7 +248,7 @@ export class GameController
if (trader.base.repair?.quality) if (trader.base.repair?.quality)
{ {
this.logger.warning(`Trader ${trader.base._id} ${trader.base.name} is missing a repair quality value, adding in default value`); this.logger.warning(`Trader ${trader.base._id} ${trader.base.nickname} is missing a repair quality value, adding in default value`);
trader.base.repair.quality = this.databaseServer.getTables().traders.ragfair.base.repair.quality; trader.base.repair.quality = this.databaseServer.getTables().traders.ragfair.base.repair.quality;
} }
} }