refactor MediaGroup. Add database
This commit is contained in:
@@ -4,6 +4,8 @@ import sys
|
||||
|
||||
from database.db import BotDB
|
||||
|
||||
current_dir = os.getcwd()
|
||||
|
||||
|
||||
class BaseDependencyFactory:
|
||||
def __init__(self):
|
||||
@@ -12,7 +14,7 @@ class BaseDependencyFactory:
|
||||
self.config = configparser.ConfigParser()
|
||||
self.config.read(config_path)
|
||||
self.settings = {}
|
||||
self.database = BotDB('database/tg-bot-database')
|
||||
self.database = BotDB(current_dir, 'database/tg-bot-database')
|
||||
|
||||
for section in self.config.sections():
|
||||
self.settings[section] = {}
|
||||
|
||||
Reference in New Issue
Block a user