- .logignore now supports targeting channels and users

- .logignore now lists all ignored channels and users when no parameter is provided
- Renamed and cleaned up some log-related fields
This commit is contained in:
Kwoth
2021-09-21 22:39:06 +02:00
parent 611817f78a
commit c9e89e1911
13 changed files with 2882 additions and 120 deletions

View File

@@ -1,8 +0,0 @@
namespace NadekoBot.Services.Database.Models
{
public class IgnoredLogChannel : DbEntity
{
public LogSetting LogSetting { get; set; }
public ulong ChannelId { get; set; }
}
}

View File

@@ -0,0 +1,15 @@
namespace NadekoBot.Services.Database.Models
{
public class IgnoredLogItem : DbEntity
{
public LogSetting LogSetting { get; set; }
public ulong LogItemId { get; set; }
public IgnoredItemType ItemType { get; set; }
}
public enum IgnoredItemType
{
Channel,
User,
}
}

View File

@@ -4,8 +4,7 @@ namespace NadekoBot.Services.Database.Models
{
public class LogSetting : DbEntity
{
public HashSet<IgnoredLogChannel> IgnoredChannels { get; set; } = new HashSet<IgnoredLogChannel>();
public HashSet<IgnoredVoicePresenceChannel> IgnoredVoicePresenceChannelIds { get; set; } = new HashSet<IgnoredVoicePresenceChannel>();
public List<IgnoredLogItem> LogIgnores { get; set; } = new List<IgnoredLogItem>();
public ulong GuildId { get; set; }
public ulong? LogOtherId { get; set; }