Skip to content

Commit e92e21f

Browse files
committed
fix: automatic module disactivation on requirement updates
1 parent 61ab9e6 commit e92e21f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

core/modules/modAutoverifactu.class.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -250,9 +250,9 @@ public function __construct($db)
250250
*/
251251
public function init($options = '')
252252
{
253-
global $db, $conf, $langs;
253+
// global $db, $conf, $langs;
254254

255-
dolibarr_set_const($db, 'FAC_FORCE_DATE_VALIDATION', '1', 'chaine', 0, '', 0);
255+
autoverifactu_set_const('FAC_FORCE_DATE_VALIDATION', '1');
256256

257257
// Create tables of module at module activation
258258
// $result = $this->_load_tables('/autoverifactu/sql/');

lib/validation.lib.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ function autoverifactuEnabled()
349349
$enabled = getDolGlobalInt('AUTOVERIFACTU_ENABLED');
350350

351351
if (!$check && $enabled) {
352-
dolibarr_set_const('AUTOVERIFACTU_ENABLED', false);
352+
autoverifactu_set_const('AUTOVERIFACTU_ENABLED', false);
353353
}
354354

355355
return $check && $enabled;

0 commit comments

Comments
 (0)