mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-23 19:19:32 +01:00
Add fallback if getting supybot.language from registry cache failed.
This commit is contained in:
parent
423a38770b
commit
0828b207be
@ -57,7 +57,10 @@ def getLocaleFromRegistryCache():
|
|||||||
loaded."""
|
loaded."""
|
||||||
global currentLocale
|
global currentLocale
|
||||||
import supybot.registry as registry
|
import supybot.registry as registry
|
||||||
|
try:
|
||||||
currentLocale = registry._cache['supybot.language']
|
currentLocale = registry._cache['supybot.language']
|
||||||
|
except KeyError:
|
||||||
|
pass
|
||||||
|
|
||||||
def import_conf():
|
def import_conf():
|
||||||
"""Imports the conf into this module"""
|
"""Imports the conf into this module"""
|
||||||
|
Loading…
Reference in New Issue
Block a user