1.1.1 • Published 7 years ago

telegrambotchatconfighandler v1.1.1

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

telegramBotChatConfigHandler

new ChatConfigHandler(folder, defaultConfigObject)

Safe all Files to the given folder. If a config is loaded without an existing file the defaultConfigObject will be returned instead.

chatConfigHandler.getAllConfigs()

Load all configs.

chatConfigHandler.loadConfig(chat)

config of the chat will be loaded from the folder. If the file does not exist the defaultConfigObject will be returned.

chatConfigHandler.saveConfig(chat, config)

A config object will be stored in the file of the chat.

chatConfigHandler.removeConfig(chat)

Remove the config of chat from the folder.