From f1f036576e25a1a5197fdc67d2b6adcc1675a309 Mon Sep 17 00:00:00 2001 From: PKulkoRaccoonGang Date: Thu, 29 Feb 2024 13:27:49 +0200 Subject: [PATCH] refactor: after rebase --- src/course-unit/data/thunk.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/course-unit/data/thunk.js b/src/course-unit/data/thunk.js index 1a318beb1..7d5bdc3a9 100644 --- a/src/course-unit/data/thunk.js +++ b/src/course-unit/data/thunk.js @@ -1,4 +1,5 @@ import { logError, logInfo } from '@edx/frontend-platform/logging'; +import { camelCaseObject } from '@edx/frontend-platform'; import { hideProcessingNotification, @@ -236,8 +237,9 @@ export function createNewCourseXBlock(body, callback, blockId) { try { await createCourseXblock(body).then(async (result) => { if (result) { + const formattedResult = camelCaseObject(result); if (body.category === 'vertical') { - const courseSectionVerticalData = await getCourseSectionVerticalData(result.locator); + const courseSectionVerticalData = await getCourseSectionVerticalData(formattedResult.locator); dispatch(fetchCourseSectionVerticalDataSuccess(courseSectionVerticalData)); } const courseVerticalChildrenData = await getCourseVerticalChildren(blockId);