Skip to content
Snippets Groups Projects
Commit 95913c71 authored by Eileen McNaughton's avatar Eileen McNaughton
Browse files

#2758 fix task tiles

parent 867ceba2
Branches
Tags
No related merge requests found
......@@ -47,7 +47,7 @@ abstract class CRM_Core_Task {
*
* @var array
*/
public static $_tasks = NULL;
public static $_tasks = [];
/**
* @var string
......
......@@ -151,7 +151,7 @@ class CRM_Member_Task extends CRM_Core_Task {
* set of tasks that are valid for the user
*/
public static function permissionedTaskTitles($permission, $params = []) {
$tasks = self::getTitlesFilteredByPermission(self::$_tasks, $permission === CRM_Core_Permission::EDIT);
$tasks = self::getTitlesFilteredByPermission(self::tasks(), $permission === CRM_Core_Permission::EDIT);
return parent::corePermissionedTaskTitles($tasks, $permission, $params);
}
......@@ -165,8 +165,7 @@ class CRM_Member_Task extends CRM_Core_Task {
* the set of tasks for a group of members
*/
public static function getTask($value) {
self::tasks();
if (!$value || empty(self::$_tasks[$value])) {
if (!$value || empty(self::tasks()[$value])) {
// Make the print task the default
$value = self::TASK_PRINT;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment