don't allow to check "enable e2e encryption" when enable_esessions is False. Fixes #5295

This commit is contained in:
Yann Leboulanger 2009-10-01 09:51:10 +02:00
parent c31d3e526a
commit c5b60e8df5
1 changed files with 2 additions and 1 deletions

View File

@ -2130,7 +2130,8 @@ class ChatControl(ChatControlBase, ChatCommands):
# XXX: Once we have fallback to disco, remove notexistant check
if not gajim.HAVE_PYCRYPTO or \
not gajim.capscache.is_supported(contact, NS_ESESSION) or \
gajim.capscache.is_supported(contact, 'notexistant'):
gajim.capscache.is_supported(contact, 'notexistant') or \
not gajim.config.get_per('accounts', self.account, 'enable_esessions'):
toggle_e2e_menuitem.set_sensitive(False)
else:
toggle_e2e_menuitem.set_active(e2e_is_active)