mirror of
https://github.com/Tyrrrz/DiscordChatExporter.git
synced 2026-04-27 08:23:03 +00:00
Refactor message grouping from data layer to render layer
This commit is contained in:
@@ -12,10 +12,8 @@ namespace DiscordChatExporter.Cli
|
||||
SimpleIoc.Default.Reset();
|
||||
|
||||
// Services
|
||||
SimpleIoc.Default.Register<IChatLogService, ChatLogService>();
|
||||
SimpleIoc.Default.Register<IDataService, DataService>();
|
||||
SimpleIoc.Default.Register<IExportService, ExportService>();
|
||||
SimpleIoc.Default.Register<IMessageGroupService, MessageGroupService>();
|
||||
SimpleIoc.Default.Register<ISettingsService, SettingsService>();
|
||||
SimpleIoc.Default.Register<IUpdateService, UpdateService>();
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace DiscordChatExporter.Cli.Verbs
|
||||
// Get services
|
||||
var container = new Container();
|
||||
var settingsService = container.Resolve<ISettingsService>();
|
||||
var chatLogService = container.Resolve<IChatLogService>();
|
||||
var dataService = container.Resolve<IDataService>();
|
||||
var exportService = container.Resolve<IExportService>();
|
||||
|
||||
// Configure settings
|
||||
@@ -30,7 +30,7 @@ namespace DiscordChatExporter.Cli.Verbs
|
||||
settingsService.MessageGroupLimit = Options.MessageGroupLimit;
|
||||
|
||||
// Get chat log
|
||||
var chatLog = await chatLogService.GetChatLogAsync(Options.GetToken(), Options.ChannelId,
|
||||
var chatLog = await dataService.GetChatLogAsync(Options.GetToken(), Options.ChannelId,
|
||||
Options.After, Options.Before);
|
||||
|
||||
// Generate file path if not set
|
||||
|
||||
Reference in New Issue
Block a user