diff --git a/salt/states/jboss7.py b/salt/states/jboss7.py index 67db6cb5f2..0272e96e4c 100644 --- a/salt/states/jboss7.py +++ b/salt/states/jboss7.py @@ -531,6 +531,12 @@ def __check_dict_contains(dct, dict_name, keys, comment='', result=True): def __append_comment(new_comment, current_comment=''): + if current_comment is None and new_comment is None: + return '' + if current_comment is None: + return new_comment + if new_comment is None: + return current_comment return current_comment+'\n'+new_comment