From: Coleman Watts Date: Mon, 28 Dec 2015 19:14:36 +0000 (-0500) Subject: Avoid calling displayValue for no reason X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=2e894314859acc0e201cea5ffa23b55e9c25d95e;p=civicrm-core.git Avoid calling displayValue for no reason --- diff --git a/CRM/Case/XMLProcessor/Report.php b/CRM/Case/XMLProcessor/Report.php index dcb3ef9210..3d4156d697 100644 --- a/CRM/Case/XMLProcessor/Report.php +++ b/CRM/Case/XMLProcessor/Report.php @@ -553,11 +553,13 @@ WHERE a.id = %1 if ($dao->fetch()) { $customGroup = array(); foreach ($typeValues[$tableName] as $columnName => $typeValue) { - $value = CRM_Core_BAO_CustomField::displayValue($dao->$columnName, $typeValue['fieldID']); if (CRM_Utils_Array::value('type', $typeValue) == 'Date') { $value = $dao->$columnName; } + else { + $value = CRM_Core_BAO_CustomField::displayValue($dao->$columnName, $typeValue['fieldID']); + } if ($value) { // Note: this is already taken care in getDisplayValue above, but sometimes