Author: asterix Date: 2008-02-04 23:17:35 +0100 (Mon, 04 Feb 2008) New Revision: 9298
Modified: trunk/src/common/connection.py Log: fix creation of new accounts
Modified: trunk/src/common/connection.py =================================================================== --- trunk/src/common/connection.py 2008-02-04 22:15:00 UTC (rev 9297) +++ trunk/src/common/connection.py 2008-02-04 22:17:35 UTC (rev 9298) @@ -551,8 +551,12 @@
def connect_to_next_host(self, retry = False): if len(self._hosts): - self._connection_types = gajim.config.get_per('accounts', self.name, - 'connection_types').split() + # No config option exist when creating a new account + if self.name in gajim.config.get_per('accounts'): + self._connection_types = gajim.config.get_per('accounts', self.name, + 'connection_types').split() + else: + self._connection_types = ['tls', 'ssl', 'plain'] host = self.select_next_host(self._hosts) self._current_host = host self._hosts.remove(host)