private async void Client_OnUntimeout(object sender, OnUntimeoutArgs e) { UserEntry user = await Program.Users.GetUserByTwitchID(e.UntimeoutedUserId); if (user != null) { await Core.LOG(new LogEntry(LOGSEVERITY.INFO, EXTENSIONNAME, $"{_twitchChannelName} :: {e.UntimeoutedBy} removed timeout on {user._twitchDisplayname}" )); } }
private void PubSubService_OnUntimeout(object sender, OnUntimeoutArgs e) { if (!UserIdChannelName.TryGetValue(e.ChannelId, out var channelName)) { return; } OnUserUntimedout?.Invoke(this, new UserUntimedoutEvent { Username = e.UntimeoutedUser, UntimedoutBy = e.UntimeoutedBy, Channel = channelName }); }
private async void OnUntimeout(object sender, OnUntimeoutArgs e) { Utils.LogToConsole($"User {e.UntimeoutedUser} ({e.UntimeoutedUserId}) untimed out by {e.UntimeoutedBy} " + $"({e.UntimeoutedByUserId})"); await SendActionAsync(new ActionTaken { ModUsername = e.UntimeoutedBy, UserUsername = e.UntimeoutedUser, Action = "untimeout", Duration = 0, Reason = "(none)" }); }
/// <summary> /// Passes <see cref="OnUntimeout"/> events down to subscribed plugins. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">An <see cref="OnUntimeoutArgs"/> object.</param> private void TwitchPubSub_OnUntimeout(object sender, OnUntimeoutArgs e) => OnUntimeout?.Invoke(this, e);
private void PubSub_OnUntimeout(object sender, OnUntimeoutArgs e) { _logger.Information($"{e.UntimeoutedUser} undid the timeout of {e.UntimeoutedUser}"); }