From 24f182449c95dec792767c1ef871c67eebaca377 Mon Sep 17 00:00:00 2001 From: David Thompson Date: Mon, 14 Jul 2014 13:07:11 -0400 Subject: [PATCH] Simplify _isBlacklisted method. --- trustcommerce.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/trustcommerce.php b/trustcommerce.php index f6e5e80..ce6f4b9 100644 --- a/trustcommerce.php +++ b/trustcommerce.php @@ -151,13 +151,11 @@ class org_fsf_payment_trustcommerce extends CRM_Core_Payment { } } + /* Return TRUE when client is either IP or agent blacklisted, or + * FALSE otherwise. + */ function _isBlacklisted() { - if($this->_isIPBlacklisted()) { - return TRUE; - } else if($this->_IsAgentBlacklisted()) { - return TRUE; - } - return FALSE; + return $this->_isIPBlacklisted() || $this->_IsAgentBlacklisted(); } function _isAgentBlacklisted() { -- 2.25.1