mirror of
https://github.com/RaidMax/IW4M-Admin.git
synced 2025-06-09 23:00:57 -05:00
Merge branch '2.3' into 2.4-pr
This commit is contained in:
@ -235,5 +235,11 @@ namespace SharedLibraryCore
|
||||
return this;
|
||||
});
|
||||
}
|
||||
|
||||
public GameEvent Wait()
|
||||
{
|
||||
OnProcessed.Wait();
|
||||
return this;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -146,6 +146,19 @@ namespace SharedLibraryCore.Services
|
||||
.Where(_client => _client.AliasLinkId == oldAliasLink.AliasLinkId)
|
||||
.ForEachAsync(_client => _client.AliasLinkId = newAliasLink.AliasLinkId);
|
||||
|
||||
// we also need to update all the penalties or they get deleted
|
||||
// scenario
|
||||
// link1 joins with ip1
|
||||
// link2 joins with ip2,
|
||||
// link2 receives penalty
|
||||
// link2 joins with ip1
|
||||
// pre existing link for link2 detected
|
||||
// link2 is deleted
|
||||
// link2 penalties are orphaned
|
||||
await context.Penalties
|
||||
.Where(_penalty => _penalty.LinkId == oldAliasLink.AliasLinkId)
|
||||
.ForEachAsync(_penalty => _penalty.LinkId = newAliasLink.AliasLinkId);
|
||||
|
||||
entity.AliasLink = newAliasLink;
|
||||
entity.AliasLinkId = newAliasLink.AliasLinkId;
|
||||
|
||||
|
Reference in New Issue
Block a user