sharp-chat/SharpChat.Common/Events/UserDisconnectEvent.cs

17 lines
443 B
C#
Raw Permalink Normal View History

2022-08-30 15:05:29 +00:00
using SharpChat.Users;
using System;
namespace SharpChat.Events {
[Event(TYPE)]
public class UserDisconnectEvent : Event {
public const string TYPE = @"user:disconnect";
public UserDisconnectReason Reason { get; }
public UserDisconnectEvent(IUser user, UserDisconnectReason reason)
: base(user ?? throw new ArgumentNullException(nameof(user))) {
Reason = reason;
}
}
}