From 56db7d6c647f5c0b4708977ab3592c1e4d791b66 Mon Sep 17 00:00:00 2001 From: Florian Mortgat Date: Thu, 22 Oct 2020 15:09:48 +0200 Subject: [PATCH] FIX: also check if there is a method $object->fetch_thirdparty() before calling it --- htdocs/core/tpl/card_presend.tpl.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/tpl/card_presend.tpl.php b/htdocs/core/tpl/card_presend.tpl.php index 479b4b694aa..d9097ee0919 100644 --- a/htdocs/core/tpl/card_presend.tpl.php +++ b/htdocs/core/tpl/card_presend.tpl.php @@ -180,7 +180,7 @@ if ($action == 'presend') } else { - if (!empty($object->socid) && empty($object->thirdparty)) { + if (!empty($object->socid) && empty($object->thirdparty) && method_exists($object, 'fetch_thirdparty')) { $object->fetch_thirdparty(); } if (is_object($object->thirdparty))