Mercurial > libervia-backend
diff src/plugins/plugin_xep_0054.py @ 365:efbfccfed623
core: local_dir moved to config file
- ~/.sat.conf added to potential config file location
- removed useless profile param from getConfig
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 18 Jun 2011 17:56:59 +0200 |
parents | 7c79d4a8c9e6 |
children | f964dcec1611 |
line wrap: on
line diff
--- a/src/plugins/plugin_xep_0054.py Sat Jun 18 16:22:50 2011 +0200 +++ b/src/plugins/plugin_xep_0054.py Sat Jun 18 17:56:59 2011 +0200 @@ -41,7 +41,7 @@ except ImportError: from wokkel.subprotocols import XMPPHandler -AVATAR_PATH = "/avatars" +AVATAR_PATH = "avatars" IQ_GET = '/iq[@type="get"]' NS_VCARD = 'vcard-temp' @@ -67,7 +67,7 @@ def __init__(self, host): info(_("Plugin XEP_0054 initialization")) self.host = host - self.avatar_path = os.path.expanduser(self.host.get_const('local_dir') + AVATAR_PATH) + self.avatar_path = os.path.join(self.host.memory.getConfig('', 'local_dir'), AVATAR_PATH) self.vcard_cache = host.memory.getPrivate("vcard_cache") or {} #used to store nicknames and avatar, key = jid if not os.path.exists(self.avatar_path): os.makedirs(self.avatar_path)