chore: refactor payment settings

This commit is contained in:
Jannat Patel
2024-09-30 18:30:53 +05:30
parent b6bf9c0032
commit 008cc66cdd
12 changed files with 314 additions and 149 deletions

View File

@@ -244,7 +244,10 @@ const lesson = createResource({
onSuccess(data) {
lessonProgress.value = data.membership?.progress
if (data.content) editor.value = renderEditor('editor', data.content)
if (JSON.parse(data.instructor_content)?.blocks?.length > 1)
if (
data.instructor_content &&
JSON.parse(data.instructor_content)?.blocks?.length > 1
)
instructorEditor.value = renderEditor(
'instructor-content',
data.instructor_content