diff --git a/htdocs/admin/remotestore/class/externalModules.class.php b/htdocs/admin/remotestore/class/externalModules.class.php index 72584d6f63b..b683f3cf7fe 100644 --- a/htdocs/admin/remotestore/class/externalModules.class.php +++ b/htdocs/admin/remotestore/class/externalModules.class.php @@ -574,7 +574,7 @@ class ExternalModules } // Direct install - if (($product['direct-download'] && $product['direct-download'] == 'yes') || $product['source'] === 'dolistore') { + if (($product['direct-download'] && in_array($product['direct-download'], array('yes', 'dolistore'))) || $product['source'] === 'dolistore') { $urldownload = ''; if ($product['source'] === 'githubcommunity') { @@ -591,7 +591,7 @@ class ExternalModules // For community modules, we download from community repo. // But we can force to download from dolistore if MAIN_DOWNLOAD_FROM_DOLISTORE_IN_PRIORITY is set (less reliable, less up to date) - if (getDolGlobalString("MAIN_DOWNLOAD_FROM_DOLISTORE_IN_PRIORITY")) { + if ($product["direct-download"] == 'dolistore' || $product['source'] === 'dolistore' || getDolGlobalString("MAIN_DOWNLOAD_FROM_DOLISTORE_IN_PRIORITY")) { if (preg_match('/https:.*\?id=(\d+)$/', $urlview, $reg)) { $urldownload = 'https://www.dolistore.com/_service_download.php?t=free&p='.$reg[1]; } @@ -698,8 +698,7 @@ class ExternalModules // Price - do not load if display none $html .= '