Merge branch 'general-devel' of github.com:NyxStudios/TShock into general-devel
This commit is contained in:
commit
6f723820a0
1 changed files with 10 additions and 8 deletions
|
|
@ -409,6 +409,8 @@ namespace TShockAPI
|
||||||
KnownIps = JsonConvert.DeserializeObject<List<String>>(args.Player.User.KnownIps);
|
KnownIps = JsonConvert.DeserializeObject<List<String>>(args.Player.User.KnownIps);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (KnownIps.Count > 0)
|
||||||
|
{
|
||||||
bool last = KnownIps.Last() == args.Player.IP;
|
bool last = KnownIps.Last() == args.Player.IP;
|
||||||
if (!last)
|
if (!last)
|
||||||
{
|
{
|
||||||
|
|
@ -419,7 +421,7 @@ namespace TShockAPI
|
||||||
|
|
||||||
KnownIps.Add(args.Player.IP);
|
KnownIps.Add(args.Player.IP);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
args.Player.User.KnownIps = JsonConvert.SerializeObject(KnownIps, Formatting.Indented);
|
args.Player.User.KnownIps = JsonConvert.SerializeObject(KnownIps, Formatting.Indented);
|
||||||
Users.UpdateLogin(args.Player.User);
|
Users.UpdateLogin(args.Player.User);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue