From 0b8bda212cab613a802ee62ac189c1181934130b Mon Sep 17 00:00:00 2001 From: Konstantin Gizdov Date: Tue, 9 Feb 2021 01:19:17 +0200 Subject: [PATCH] fix inconsistent logic --- templates/config.yaml.j2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/config.yaml.j2 b/templates/config.yaml.j2 index ca3d3dc..5d5810f 100644 --- a/templates/config.yaml.j2 +++ b/templates/config.yaml.j2 @@ -150,7 +150,7 @@ retention: {% if borg_prune_prefix is defined %} prefix: '{{ borg_prune_prefix | replace("'", "") }}' {% else %} -{{ ('No custom archive name format provided.' if borg_archive_name_format is defined) | mandatory('Custom value for borg_archive_name_format was specified without providing the matching prune prefix. Please specify borg_prune_prefix as well.') }} +{{ (' # No custom archive name format provided.' if borg_archive_name_format is not defined) | mandatory('Custom value for borg_archive_name_format was specified without providing the matching prune prefix. Please specify borg_prune_prefix as well.') }} prefix: '{hostname}-' {% endif %} @@ -182,7 +182,7 @@ consistency: {% elif borg_prune_prefix is defined %} prefix: '{{ borg_prune_prefix | replace("'", "") }}' {% else %} -{{ ('No custom archive name format provided.' if borg_archive_name_format is defined) | mandatory('Custom value for borg_archive_name_format was specified without providing the matching consistency check prefix. Please specify borg_check_prefix as well.') }} +{{ (' # No custom archive name format provided.' if borg_archive_name_format is not defined) | mandatory('Custom value for borg_archive_name_format was specified without providing the matching consistency check prefix. Please specify borg_check_prefix as well.') }} prefix: '{hostname}-' {% endif %}