From: jitendrapurohit Date: Wed, 22 Apr 2015 13:10:52 +0000 (+0530) Subject: optimised changes X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=d931a208427c23a8347ea593bf4d7eb01e716e88;p=civicrm-core.git optimised changes --- diff --git a/CRM/Event/Form/Task/Delete.php b/CRM/Event/Form/Task/Delete.php index c69c8a9dab..595da7f8bd 100644 --- a/CRM/Event/Form/Task/Delete.php +++ b/CRM/Event/Form/Task/Delete.php @@ -117,7 +117,7 @@ class CRM_Event_Form_Task_Delete extends CRM_Event_Form_Task { } // delete participant only if it is not an additional participant // or if it is additional and its primary participant is not selected in $this->_participantIds. - elseif ($primaryParticipantId == NULL || ($primaryParticipantId != NULL && !CRM_Utils_Array::crmInArray($primaryParticipantId, $this->_participantIds))) { + elseif (empty($primaryParticipantId) || (!in_array($primaryParticipantId, $this->_participantIds))) { CRM_Event_BAO_Participant::deleteParticipant($participantId); $deletedParticipants++; }