From 621709ed421eceb95ae90e36060418d7b8dbe271 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 10 Apr 2019 16:54:20 +0200 Subject: [PATCH] FIX check thirdparty defined when PROJECT_THIRDPARTY_REQUIRED is set --- htdocs/projet/class/project.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/projet/class/project.class.php b/htdocs/projet/class/project.class.php index 779666b4b9d..59d24e5eb3d 100644 --- a/htdocs/projet/class/project.class.php +++ b/htdocs/projet/class/project.class.php @@ -190,10 +190,10 @@ class Project extends CommonObject dol_syslog(get_class($this)."::create error -1 ref null", LOG_ERR); return -1; } - if (! empty($conf->global->PROJECT_THIRDPARTY_REQUIRED) && ! $this->socid > 0) + if (! empty($conf->global->PROJECT_THIRDPARTY_REQUIRED) && ! ($this->socid > 0)) { $this->error = 'ErrorFieldsRequired'; - dol_syslog(get_class($this)."::create error -1 ref null", LOG_ERR); + dol_syslog(get_class($this)."::create error -1 thirdparty not defined and option PROJECT_THIRDPARTY_REQUIRED is set", LOG_ERR); return -1; }