File tree Expand file tree Collapse file tree
classes/suggested-tasks/providers/integrations/yoast Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ class Add_Yoast_Providers {
1515 /**
1616 * Providers.
1717 *
18- * @var array
18+ * @var (\Progress_Planner\Suggested_Tasks\Providers\Integrations\Yoast\Yoast_Provider|\Progress_Planner\Suggested_Tasks\Providers\Tasks)[]
1919 */
2020 protected $ providers = [];
2121
@@ -48,10 +48,12 @@ public function enqueue_assets( $hook ) {
4848
4949 // Add Ravi icon if the task is pending or is completed.
5050 if ( $ provider ->is_task_relevant () || \progress_planner ()->get_suggested_tasks ()->was_task_completed ( $ provider ->get_task_id () ) ) {
51- $ focus_task = $ provider ->get_focus_tasks ();
51+ if ( method_exists ( $ provider , 'get_focus_tasks ' ) ) {
52+ $ focus_task = $ provider ->get_focus_tasks ();
5253
53- if ( $ focus_task ) {
54- $ focus_tasks = array_merge ( $ focus_tasks , $ focus_task );
54+ if ( $ focus_task ) {
55+ $ focus_tasks = array_merge ( $ focus_tasks , $ focus_task );
56+ }
5557 }
5658 }
5759 }
You can’t perform that action at this time.
0 commit comments