diff --git a/htdocs/admin/tools/listevents.php b/htdocs/admin/tools/listevents.php index 78a3f8948d4..2b832910623 100644 --- a/htdocs/admin/tools/listevents.php +++ b/htdocs/admin/tools/listevents.php @@ -219,7 +219,7 @@ if ($result) if ($search_user) $param .= '&search_user='.urlencode($search_user); if ($search_desc) $param .= '&search_desc='.urlencode($search_desc); if ($search_ua) $param .= '&search_ua='.urlencode($search_ua); - if ($search_prefix_sessiona) $param .= '&search_prefix_session='.urlencode($search_prefix_session); + if ($search_prefix_session) $param .= '&search_prefix_session='.urlencode($search_prefix_session); if ($date_startmonth) $param .= "&date_startmonth=".urlencode($date_startmonth); if ($date_startday) $param .= "&date_startday=".urlencode($date_startday); if ($date_startyear) $param .= "&date_startyear=".urlencode($date_startyear); diff --git a/htdocs/webservices/server_thirdparty.php b/htdocs/webservices/server_thirdparty.php index 4bed0e1be3b..7c97159d0bb 100644 --- a/htdocs/webservices/server_thirdparty.php +++ b/htdocs/webservices/server_thirdparty.php @@ -510,7 +510,7 @@ function createThirdParty($authentication, $thirdparty) $db->commit(); // Patch to add capability to associate (one) sale representative - if ($thirdparty['commid'] && $thirdparty['commid'] > 0) + if (!empty($thirdparty['commid']) && $thirdparty['commid'] > 0) $newobject->add_commercial($fuser, $thirdparty["commid"]); $objectresp = array('result'=>array('result_code'=>'OK', 'result_label'=>''), 'id'=>$newobject->id, 'ref'=>$newobject->ref);