From 3b74d099424ad5971f0c072fdf17d98a8a141ae1 Mon Sep 17 00:00:00 2001 From: MDW Date: Tue, 19 Mar 2024 23:04:27 +0100 Subject: [PATCH] Replace is_object with explicit instance test --- htdocs/stripe/class/actions_stripe.class.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/htdocs/stripe/class/actions_stripe.class.php b/htdocs/stripe/class/actions_stripe.class.php index d4b931a8bc5..51522e73b29 100644 --- a/htdocs/stripe/class/actions_stripe.class.php +++ b/htdocs/stripe/class/actions_stripe.class.php @@ -2,6 +2,7 @@ /* Copyright (C) 2009-2016 Regis Houssin * Copyright (C) 2011 Herve Prot * Copyright (C) 2014 Philippe Grand + * Copyright (C) 2024 MDW * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -96,7 +97,7 @@ class ActionsStripeconnect extends CommonHookActions $this->resprints .= $langs->trans("NoStripe"); } $this->resprints .= ''; - } elseif (is_object($object) && $object->element == 'member') { + } elseif ($object instanceof CommonObject && $object->element == 'member') { $this->resprints .= ''; $this->resprints .= ''; - } elseif (is_object($object) && $object->element == 'adherent_type') { + } elseif ($object instanceof CommonObject && $object->element == 'adherent_type') { $this->resprints .= '
'; $this->resprints .= $langs->trans('StripeCustomer'); @@ -130,7 +131,7 @@ class ActionsStripeconnect extends CommonHookActions $this->resprints .= $langs->trans("NoStripe"); } $this->resprints .= '
'; $this->resprints .= '
'; $this->resprints .= $langs->trans('PlanStripe');