// TODO: Fix this method's name private void PublishMessages() { var messages = _repository.List(DataItemPolicy <IntervalTriggeredMessage> .ActiveOnly()); foreach (var message in messages) { _autoMsgSystem.Publish(message); } }
public static BotMain NewBot(TwitchClientSettings clientSettings, EfGenericRepo efGenericRepo) { var chatClients = new List <IChatClient> { new ConsoleChatClient(), new TwitchChatClient(clientSettings), }; var commandMessages = efGenericRepo.List(DataItemPolicy <SimpleResponseMessage> .ActiveOnly()); var commandHandler = new CommandHandler(chatClients, commandMessages); var subscriberHandler = new SubscriberHandler(chatClients); var followerHandler = new FollowerHandler(chatClients); var botMain = new BotMain(chatClients, efGenericRepo, commandHandler, subscriberHandler, followerHandler); return(botMain); }