diff --git a/htdocs/comm/propal/class/propal.class.php b/htdocs/comm/propal/class/propal.class.php index 16d2edd0e96..12dbbe7d1c1 100644 --- a/htdocs/comm/propal/class/propal.class.php +++ b/htdocs/comm/propal/class/propal.class.php @@ -651,7 +651,7 @@ class Propal extends CommonObject * @param int $notrigger 1=Does not execute triggers, 0= execuete triggers * @return int <0 if KO, >=0 if OK */ - function create($user='', $notrigger=0) + function create($user, $notrigger=0) { global $langs,$conf,$mysoc,$hookmanager; $error=0; @@ -919,7 +919,7 @@ class Propal extends CommonObject { $this->products=$this->lines; - return $this->create(); + return $this->create($user); } /** diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index 12fee9deb8b..98bee3e052c 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -3,7 +3,7 @@ * Copyright (C) 2005-2013 Regis Houssin * Copyright (C) 2010-2013 Juanjo Menent * Copyright (C) 2012 Christophe Battarel - * Copyright (C) 2010-2011 Juanjo Menent + * Copyright (C) 2010-2014 Juanjo Menent * Copyright (C) 2012-2013 Christophe Battarel * Copyright (C) 2011-2014 Philippe Grand * Copyright (C) 2012 Marcos GarcĂ­a @@ -611,8 +611,6 @@ abstract class CommonObject require_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php'; - require_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php'; - $thirdparty = new Societe($this->db); $result=$thirdparty->fetch(isset($this->socid)?$this->socid:(isset($this->fk_soc)?$this->fk_soc:$this->fk_thirdparty)); $this->client = $thirdparty; // deprecated