mirror of
https://github.com/sp-tarkov/server.git
synced 2025-02-13 09:50:43 -05:00
Fixed multiple ragfair bans being added on profile creation
This commit is contained in:
parent
ef8307540b
commit
923a92169d
@ -145,11 +145,20 @@ export class TraderHelper
|
|||||||
|
|
||||||
if (rawProfileTemplate.fleaBlockedDays > 0)
|
if (rawProfileTemplate.fleaBlockedDays > 0)
|
||||||
{
|
{
|
||||||
pmcData.Info.Bans.push(
|
const newBanDateTime = this.timeUtil.getTimeStampFromNowDays(rawProfileTemplate.fleaBlockedDays);
|
||||||
{
|
const existingBan = pmcData.Info.Bans.find((ban) => ban.banType === BanType.RAGFAIR);
|
||||||
banType: BanType.RAGFAIR,
|
if (existingBan)
|
||||||
dateTime: this.timeUtil.getTimeStampFromNowDays(rawProfileTemplate.fleaBlockedDays),
|
{
|
||||||
});
|
existingBan.dateTime = newBanDateTime;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
pmcData.Info.Bans.push(
|
||||||
|
{
|
||||||
|
banType: BanType.RAGFAIR,
|
||||||
|
dateTime: newBanDateTime,
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (traderID === Traders.JAEGER)
|
if (traderID === Traders.JAEGER)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user