add a message parser to vote controller
parses a vote message line by line to extract - eventdate - eventid - movies - votes This depends on the structure of the message to not change substantially. as such it's quite brittle
This commit is contained in:
@ -10,6 +10,7 @@ import { logger } from "../logger";
|
||||
import { CommandType } from "../types/commandTypes";
|
||||
import { isInitialAnnouncement } from "../helper/messageIdentifiers";
|
||||
import VoteController from "../helper/vote.controller";
|
||||
import { yavinJellyfinHandler } from "../..";
|
||||
|
||||
|
||||
|
||||
@ -17,7 +18,7 @@ export class ExtendedClient extends Client {
|
||||
private eventFilePath = `${__dirname}/../events`
|
||||
private commandFilePath = `${__dirname}/../commands`
|
||||
private jellyfin: JellyfinHandler
|
||||
public voteController: VoteController = new VoteController()
|
||||
public voteController: VoteController = new VoteController(this, yavinJellyfinHandler)
|
||||
public commands: Collection<string, CommandType> = new Collection()
|
||||
private announcementChannels: Collection<string, TextChannel> = new Collection() //guildId to TextChannel
|
||||
private announcementRoleHandlerTask: Collection<string, ScheduledTask> = new Collection() //one task per guild
|
||||
|
Reference in New Issue
Block a user