Skip to content
Snippets Groups Projects
Commit 62801532 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Add a protection for duplicate modules

parent 5edcc198
Branches
Tags
No related merge requests found
...@@ -124,7 +124,7 @@ foreach ($modulesdir as $dir) ...@@ -124,7 +124,7 @@ foreach ($modulesdir as $dir)
if ($modName) if ($modName)
{ {
if (in_array($modName,$modNameLoaded)) if (! empty($modNameLoaded[$modName]))
{ {
$mesg="Error: Module ".$modName." was found twice: Into ".$modNameLoaded[$modName]." and ".$dir.". You probably have an old file on your disk.<br>"; $mesg="Error: Module ".$modName." was found twice: Into ".$modNameLoaded[$modName]." and ".$dir.". You probably have an old file on your disk.<br>";
dol_syslog($mesg, LOG_ERR); dol_syslog($mesg, LOG_ERR);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment