diff --git a/htdocs/modulebuilder/template/myobject_agenda.php b/htdocs/modulebuilder/template/myobject_agenda.php
index c752dd41632..81d8c93f240 100644
--- a/htdocs/modulebuilder/template/myobject_agenda.php
+++ b/htdocs/modulebuilder/template/myobject_agenda.php
@@ -211,7 +211,7 @@ if ($object->id > 0) {
// Thirdparty
$morehtmlref.='
'.$langs->trans('ThirdParty') . ' : ' . (is_object($object->thirdparty) ? $object->thirdparty->getNomUrl(1) : '');
// Project
- if (!empty($conf->project->enabled)) {
+ if (isModEnabled('project')) {
$langs->load("projects");
$morehtmlref.='
'.$langs->trans('Project') . ' ';
if ($permissiontoadd) {