/** * @param Task $tasks * @return $this */ public function addTask(Task $tasks) { $tasks->addUser($this); $this->tasks[] = $tasks; return $this; }