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:
// 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.'));
'Print PDF Letter'
);
- if (in_array($activityTypeId, array(
+ if (in_array($activityTypeId, [
$emailTypeValue,
$letterTypeValue,
- ))) {
+ ])) {
return;
}
}