2
0
forked from Wavyzz/dolibarr

Fix warning

This commit is contained in:
Laurent Destailleur
2022-05-24 21:25:47 +02:00
parent 259a292704
commit 51a53985fd

View File

@@ -147,7 +147,7 @@ if ($socid > 0) {
$objcon = new stdClass();
$out = '';
$permok = $user->rights->agenda->myactions->create;
$permok = $user->hasRight('agenda', 'myactions', 'create');
if ((!empty($objthirdparty->id) || !empty($objcon->id)) && $permok) {
if (is_object($objthirdparty) && get_class($objthirdparty) == 'Societe') {
$out .= '&originid='.$objthirdparty->id.($objthirdparty->id > 0 ? '&socid='.$objthirdparty->id : '').'&backtopage='.urlencode($_SERVER['PHP_SELF'].($objthirdparty->id > 0 ? '?socid='.$objthirdparty->id : ''));