sharp-chat/SharpChat.DataProvider.Misuzu/Users/MisuzuUserBumpInfo.cs

19 lines
499 B
C#
Raw Permalink Normal View History

2022-08-30 15:05:29 +00:00
using SharpChat.Users.Remote;
using System.Linq;
using System.Text.Json.Serialization;
namespace SharpChat.DataProvider.Misuzu.Users {
public class MisuzuUserBumpInfo {
[JsonPropertyName(@"id")]
public long UserId { get; }
[JsonPropertyName(@"ip")]
public string UserIP { get; }
public MisuzuUserBumpInfo(UserBumpInfo ubi) {
UserId = ubi.User.UserId;
UserIP = ubi.Sessions.First().RemoteAddress.ToString();
}
}
}