X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FActivity%2FPage%2FTab.php;h=4415618a7e2f0ecb2b82032d82e7e3acb14de731;hb=62d3ee279943eae74d2f4d5797f8bb3b3fcbfa5a;hp=305c9dd8b6d4afbded841f7411c725145228e65e;hpb=d880d1db343ce51a575d446d2748e3e1e5468277;p=civicrm-core.git diff --git a/CRM/Activity/Page/Tab.php b/CRM/Activity/Page/Tab.php index 305c9dd8b6..4415618a7e 100644 --- a/CRM/Activity/Page/Tab.php +++ b/CRM/Activity/Page/Tab.php @@ -3,7 +3,7 @@ +--------------------------------------------------------------------+ | CiviCRM version 5 | +--------------------------------------------------------------------+ - | Copyright CiviCRM LLC (c) 2004-2018 | + | Copyright CiviCRM LLC (c) 2004-2019 | +--------------------------------------------------------------------+ | This file is a part of CiviCRM. | | | @@ -28,7 +28,7 @@ /** * * @package CRM - * @copyright CiviCRM LLC (c) 2004-2018 + * @copyright CiviCRM LLC (c) 2004-2019 */ /** @@ -86,12 +86,12 @@ class CRM_Activity_Page_Tab extends CRM_Core_Page { switch ($activityTypeId) { case $emailTypeValue: $wrapper = new CRM_Utils_Wrapper(); - $arguments = array('attachUpload' => 1); + $arguments = ['attachUpload' => 1]; return $wrapper->run('CRM_Contact_Form_Task_Email', ts('Email a Contact'), $arguments); case $letterTypeValue: $wrapper = new CRM_Utils_Wrapper(); - $arguments = array('attachUpload' => 1); + $arguments = ['attachUpload' => 1]; return $wrapper->run('CRM_Contact_Form_Task_PDF', ts('Create PDF Letter'), $arguments); default: @@ -167,7 +167,7 @@ class CRM_Activity_Page_Tab extends CRM_Core_Page { // Do check for view/edit operation. if ($this->_id && - in_array($action, array(CRM_Core_Action::UPDATE, CRM_Core_Action::VIEW)) + in_array($action, [CRM_Core_Action::UPDATE, CRM_Core_Action::VIEW]) ) { if (!CRM_Activity_BAO_Activity::checkPermission($this->_id, $action)) { CRM_Core_Error::fatal(ts('You are not authorized to access this page.')); @@ -200,10 +200,10 @@ class CRM_Activity_Page_Tab extends CRM_Core_Page { 'Print PDF Letter' ); - if (in_array($activityTypeId, array( + if (in_array($activityTypeId, [ $emailTypeValue, $letterTypeValue, - ))) { + ])) { return; } }