autoreader

Automatically read posts older than the configured interval.

Author: RaceProUK
License: MIT

autoreader.prepare(plugConfig, config, events, browser)

Prepare Plugin prior to login

Kind: static method of autoreader

Param Type Description
plugConfig * Plugin specific configuration
config Config Overall Bot Configuration
events externals.events.SockEvents EventEmitter used for the bot
browser Browser Web browser for communicating with discourse

autoreader.start()

Start the plugin after login

Kind: static method of autoreader

autoreader.stop()

Stop the plugin prior to exit or reload

Kind: static method of autoreader

autoreader.readify()

Autoread posts worker method; gets the list of accessible topics, then scans each in turn, reading any unread posts it finds that are older than the configured interval.

Kind: static method of autoreader

autoreader~defaultConfig : object

Default configuration settings

Kind: inner typedef of autoreader

defaultConfig.minAge : number

How old a post must be to be auro-read

Kind: static property of defaultConfig

defaultConfig.hour : number

The hour of the day to run the autoreader in UTC (0-23)

Kind: static property of defaultConfig
Default: 0

defaultConfig.minute : number

The minute of the hour to run the autoreader in UTC (0-59)

Kind: static property of defaultConfig
Default: 0

defaultConfig.randomize : boolean

Randomise the time of day the autoreader runs (if set, overrides hour and minute)

Kind: static property of defaultConfig
Default: true

autoreader~internals : object

Internal status store

Kind: inner typedef of autoreader

internals.browser : Browser

Browser to use for communication with discourse

Kind: static property of internals

internals.config : object

Instance configuration

Kind: static property of internals

internals.timer : object

Used to stop the autoreading when the plugin is stopped

Kind: static property of internals

internals.events : externals.events.SockEvents

EventEmitter used for internal communication

Kind: static property of internals