diff --git a/swh/templates/listers/deployment.yaml b/swh/templates/listers/deployment.yaml
index 8ab2c40dc19489f4c726917dfee1ecbb8c5c7ffa..7a82873f22def7c33224cac234a7535fcb503da0 100644
--- a/swh/templates/listers/deployment.yaml
+++ b/swh/templates/listers/deployment.yaml
@@ -97,7 +97,7 @@ spec:
           value: {{ get $deployment_config "logLevel" | default "INFO" | quote }}
         - name: SWH_CONFIG_FILENAME
           value: /etc/swh/config.yml
-        {{ if $use_json_logger -}}
+        {{ if $use_json_logger }}
         - name: SWH_LOG_CONFIG
           value: /etc/swh/logging-configuration.yml
         {{ end }}
@@ -109,7 +109,7 @@ spec:
             subPath: "pre-stop.sh"
           - name: configuration
             mountPath: /etc/swh
-        {{ if $use_json_logger -}}
+        {{ if $use_json_logger }}
           - name: configuration-template
             mountPath: /etc/swh/logging-configuration.yml
             subPath: "logging-configuration.yml"