/** * Sunch the course categories with the given list of categories. * * @param Course $course * @param array $categories * @return mixed */ public function syncCategories(Course $course, array $categories) { $categories = $this->checkForNewCategories($categories); return $this->repository->syncCoursetoCaegories($course, $categories); }