@@ -8,6 +8,7 @@ namespace Content.Server.Database
|
||||
{
|
||||
public sealed class ServerBanDef
|
||||
{
|
||||
public int? Id { get; }
|
||||
public NetUserId? UserId { get; }
|
||||
public (IPAddress address, int cidrMask)? Address { get; }
|
||||
|
||||
@@ -16,7 +17,7 @@ namespace Content.Server.Database
|
||||
public string Reason { get; }
|
||||
public NetUserId? BanningAdmin { get; }
|
||||
|
||||
public ServerBanDef(NetUserId? userId, (IPAddress, int)? address, DateTimeOffset banTime, DateTimeOffset? expirationTime, string reason, NetUserId? banningAdmin)
|
||||
public ServerBanDef(int? id, NetUserId? userId, (IPAddress, int)? address, DateTimeOffset banTime, DateTimeOffset? expirationTime, string reason, NetUserId? banningAdmin)
|
||||
{
|
||||
if (userId == null && address == null)
|
||||
{
|
||||
@@ -30,6 +31,7 @@ namespace Content.Server.Database
|
||||
address = (addr.Item1.MapToIPv4(), addr.Item2 - 96);
|
||||
}
|
||||
|
||||
Id = id;
|
||||
UserId = userId;
|
||||
Address = address;
|
||||
BanTime = banTime;
|
||||
|
||||
Reference in New Issue
Block a user