Merge pull request #11 from R4stl1n/master

update
This commit is contained in:
Mr McClain 2016-02-23 18:15:01 -06:00
commit 974698fe2c
2 changed files with 5 additions and 2 deletions

View File

@ -13,7 +13,8 @@ class NotificationHandler(logging.Handler):
notif.title = "%s [%s:%s]" % (record.levelname, record.funcName, record.lineno)
notif.level = str([item[0] for item in Notification.LEVEL_CHOICES if item[1] == record.levelname][0])
message = record.getMessage()
message = message + "\n\n"
message = message + record.exc_text
if record.exc_text:
message = message + "\n\n"
message = message + record.exc_text
notif.message = message
notif.save()

View File

@ -103,6 +103,8 @@ class OpenfireManager:
remote_groups = []
if response:
remote_groups = response['groupname']
if isinstance(remote_groups, basestring):
remote_groups = [remote_groups]
logger.debug("Openfire user %s has groups %s" % (username, remote_groups))
add_groups = []
del_groups = []