use helper func and do 80 margin

This commit is contained in:
Nikos Kouremenos 2006-01-19 09:50:53 +00:00
parent 950572c07e
commit c9d98a9494
1 changed files with 5 additions and 3 deletions

View File

@ -1422,9 +1422,11 @@ class Connection:
# Get bookmarks from private namespace
self.get_bookmarks()
# If it's a gmail account, inform the server that we want e-mail notifications
if our_jid.split('@')[1] == 'gmail.com':
gajim.log.debug(('%s is a gmail account. Setting option to get e-mail notifications on the server.') % (our_jid))
# If it's a gmail account,
# inform the server that we want e-mail notifications
if gajim.get_server_from_jid(our_jid) == 'gmail.com':
gajim.log.debug(('%s is a gmail account. Setting option '
'to get e-mail notifications on the server.') % (our_jid))
iq = common.xmpp.Iq(typ = 'set', to = our_jid)
iq.setAttr('id', 'MailNotify')
query = iq.setTag('usersetting')