From 713cfe225580746f4699a6e5130ad1392648c19b Mon Sep 17 00:00:00 2001 From: rvangenderen Date: Thu, 9 Jul 2020 10:10:18 +0200 Subject: [PATCH] create mail key if not exist --- webapp_admin/webapp_admin.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/webapp_admin/webapp_admin.py b/webapp_admin/webapp_admin.py index a8ebeb3..6fa730c 100755 --- a/webapp_admin/webapp_admin.py +++ b/webapp_admin/webapp_admin.py @@ -214,6 +214,8 @@ def backup_signature(user, location=None): except Exception as e: print('Could not load WebApp settings for user {} (Error: {})'.format(user.name, repr(e))) sys.exit(1) + if not settings['settings']['zarafa']['v1']['contexts'].get("mail"): + settings['settings']['zarafa']['v1']['contexts']['mail'] = {} if settings['settings']['zarafa']['v1']['contexts']['mail'].get('signatures'): for item in settings['settings']['zarafa']['v1']['contexts']['mail']['signatures']['all']: name = settings['settings']['zarafa']['v1']['contexts']['mail']['signatures']['all'][item]['name']