From a4567ff601c3cb0d91e814fdd845faabe3cf23f7 Mon Sep 17 00:00:00 2001 From: Navin Karkera Date: Mon, 11 Dec 2023 20:54:23 +0530 Subject: [PATCH] fix: jsdoc types --- src/course-outline/data/api.js | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/src/course-outline/data/api.js b/src/course-outline/data/api.js index a28703d24b..5714fa9ada 100644 --- a/src/course-outline/data/api.js +++ b/src/course-outline/data/api.js @@ -174,12 +174,12 @@ export async function restartIndexingOnCourse(reindexLink) { /** * Get course section - * @param {string} sectionId + * @param {string} itemId * @returns {Promise
} */ -export async function getCourseItem(sectionId) { +export async function getCourseItem(itemId) { const { data } = await getAuthenticatedHttpClient() - .get(getXBlockApiUrl(sectionId)); + .get(getXBlockApiUrl(itemId)); return camelCaseObject(data); } @@ -236,7 +236,7 @@ export async function configureCourseSection(sectionId, isVisibleToStaffOnly, st /** * Edit course section - * @param {string} sectionId + * @param {string} itemId * @param {string} displayName * @returns {Promise} */ @@ -253,7 +253,7 @@ export async function editItemDisplayName(itemId, displayName) { /** * Delete course section - * @param {string} sectionId + * @param {string} itemId * @returns {Promise} */ export async function deleteCourseItem(itemId) { @@ -265,8 +265,8 @@ export async function deleteCourseItem(itemId) { /** * Duplicate course section - * @param {string} sectionId - * @param {string} courseBlockId + * @param {string} itemId + * @param {string} parentId * @returns {Promise} */ export async function duplicateCourseItem(itemId, parentId) { @@ -281,7 +281,9 @@ export async function duplicateCourseItem(itemId, parentId) { /** * Add new course item like section, subsection or unit. - * @param {string} courseBlockId + * @param {string} parentLocator + * @param {string} category + * @param {string} displayName * @returns {Promise} */ export async function addNewCourseItem(parentLocator, category, displayName) {