From 99527bf58218b90f50e041b12017a8d12937ec14 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ma=C3=AFeul=20Rouquette?= <maieul@maieul.net>
Date: Thu, 6 Feb 2020 15:24:08 +0100
Subject: [PATCH] =?UTF-8?q?oups,=20dans=20la=20config=20d'un=20traitement,?=
 =?UTF-8?q?=20une=20case=20d=C3=A9coch=C3=A9e=20a=20bien=20une=20valeur=20?=
 =?UTF-8?q?enregistr=C3=A9=20en=20base=20(''),=20donc=20faut=20modifier=20?=
 =?UTF-8?q?le=20test?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 paquet.xml        | 2 +-
 traiter/email.php | 6 +++++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/paquet.xml b/paquet.xml
index 738df546..95151451 100644
--- a/paquet.xml
+++ b/paquet.xml
@@ -1,7 +1,7 @@
 <paquet
 	prefix="formidable"
 	categorie="communication"
-	version="4.0.3"
+	version="4.0.4"
 	etat="stable"
 	compatibilite="[3.1.0;3.2.*]"
 	logo="images/formidable-64.png"
diff --git a/traiter/email.php b/traiter/email.php
index 29ce5ceb..05544152 100644
--- a/traiter/email.php
+++ b/traiter/email.php
@@ -10,7 +10,11 @@ include_spip('inc/formidable_fichiers');
 function traiter_email_dist($args, $retours) {
 
 	// Vérifier si on doit envoyer en cas de modification de réponses
-	if (isset($retours['modification_reponse']) and  $retours['modification_reponse'] == true and isset($args['options']['modification_reponse'])) {
+	if (isset($retours['modification_reponse'])
+			and  $retours['modification_reponse'] == true
+			and isset($args['options']['modification_reponse'])
+			and $args['options']['modification_reponse'] == 'on'
+	) {
 		$retours['traitements']['email'] = true;
 		return $retours;
 	}
-- 
GitLab