When no language selected, value is 0 so it enters in the condition filter_lang != '' anyway

This commit is contained in:
Iliès BENYAHIA 2022-12-20 11:00:41 +01:00
parent f1d83b695a
commit a08c468a5e

View File

@ -408,7 +408,7 @@ class mailing_contacts1 extends MailingTargets
} }
// Filter on language // Filter on language
if ($filter_lang != '') { if (!empty($filter_lang)) {
$sql .= " AND sp.default_lang = '".$this->db->escape($filter_lang)."'"; $sql .= " AND sp.default_lang = '".$this->db->escape($filter_lang)."'";
} }
@ -439,7 +439,6 @@ class mailing_contacts1 extends MailingTargets
$sql .= " ORDER BY sp.email"; $sql .= " ORDER BY sp.email";
// print "wwwwwwx".$sql; // print "wwwwwwx".$sql;
// Stocke destinataires dans cibles // Stocke destinataires dans cibles
$result = $this->db->query($sql); $result = $this->db->query($sql);
if ($result) { if ($result) {