Skip to content
Snippets Groups Projects
Commit e2e15872 authored by Regis Houssin's avatar Regis Houssin
Browse files

Fix: problem with development version

parent f6ed7100
No related branches found
No related tags found
No related merge requests found
......@@ -98,7 +98,7 @@ function Activate($value,$withdeps=1)
}
// Test if Dolibarr version ok
$verdol=versiondolibarrarray();
$verdol=versiondolibarrarray(1);
$vermin=$objMod->need_dolibarr_version;
//print 'eee'.versioncompare($verdol,$vermin).join(',',$verdol).' - '.join(',',$vermin);exit;
if (is_array($vermin) && versioncompare($verdol,$vermin) < 0)
......
......@@ -82,9 +82,17 @@ function versionphparray()
* \brief Return version Dolibarr
* \return array Tableau de version (vermajeur,vermineur,autre)
*/
function versiondolibarrarray()
function versiondolibarrarray($fortest=0)
{
return explode('.',DOL_VERSION);
$dol_version = DOL_VERSION;
if ($fortest)
{
preg_match('/^[0-9\.]+([A-Z\-]+)$/i',DOL_VERSION,$regs);
$dol_version = preg_replace('/'.$regs[1].'/','',DOL_VERSION);
}
return explode('.',$dol_version);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment