From 632ccfdbf085987748fb24989d601ca6371b6126 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Tue, 28 Jan 2025 19:04:24 +0100 Subject: [PATCH] FIX if $force_entity = 0 ($force_entity != 'default') = false --- htdocs/core/class/html.form.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index 31c5c5521ee..ad27dc50266 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -2195,7 +2195,7 @@ class Form $sql .= " LEFT JOIN " . $this->db->prefix() . "entity as e ON e.rowid = u.entity"; } // Condition here should be the same than into societe->getSalesRepresentatives(). - if ($userissuperadminentityone && $force_entity != 'default') { + if ($userissuperadminentityone && $force_entity !== 'default') { if (!empty($force_entity)) { $sql .= " WHERE u.entity IN (0, " . $this->db->sanitize($force_entity) . ")"; } else {