From 028a5ca07652c528e52b8d209c93ffb0171c5573 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Fri, 19 Dec 2025 10:04:09 +0100 Subject: [PATCH] add more case to set share key --- htdocs/core/class/commonobject.class.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index 2cb5c18b19b..7540e8fd6d8 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -6181,6 +6181,10 @@ abstract class CommonObject $setsharekey = true; } } + if (!empty($this->TRIGGER_PREFIX) && getDolGlobalInt(strtoupper($this->TRIGGER_PREFIX."_ALLOW_EXTERNAL_DOWNLOAD"))) { + $setsharekey = true; + } + // TODO Remove case covered by trigger prefix if ($this->element == 'commande' && getDolGlobalInt("ORDER_ALLOW_EXTERNAL_DOWNLOAD")) { $setsharekey = true; }