Add list setting handler
This commit is contained in:
parent
f2e219fca1
commit
429d3ffba2
|
@ -14,6 +14,9 @@ def getSetting(section, setting, path = "config.cfg"):
|
||||||
config.read(path)
|
config.read(path)
|
||||||
return config.get(section, setting)
|
return config.get(section, setting)
|
||||||
|
|
||||||
|
def getListSetting(section, setting, path = "config.cfg"):
|
||||||
|
return ast.literal_eval(getSetting(section, setting, path))
|
||||||
|
|
||||||
def dbtype():
|
def dbtype():
|
||||||
try:
|
try:
|
||||||
return int(getSetting("Database", "type"))
|
return int(getSetting("Database", "type"))
|
||||||
|
|
Loading…
Reference in a new issue