do not update question backend id

This commit is contained in:
nflnkr 2023-12-13 20:16:34 +03:00
parent 501b5fb594
commit 80ecea27d8

@ -206,8 +206,10 @@ export const updateQuestion = (
//Если мы делаем листочек веточкой - удаляем созданный к нему результ //Если мы делаем листочек веточкой - удаляем созданный к нему результ
const questionResult = useQuestionsStore.getState().questions.find(questionResult => questionResult.type === "result" && questionResult.content.rule.parentId === q.content.id); const questionResult = useQuestionsStore.getState().questions.find(questionResult => questionResult.type === "result" && questionResult.content.rule.parentId === q.content.id);
if (questionResult && q.content.rule.default.length !== 0) deleteQuestion(questionResult.quizId); if (questionResult && q.content.rule.default.length !== 0) deleteQuestion(questionResult.quizId);
deleteQuestion;
setQuestionBackendId(questionId, response.updated); if (q.backendId !== response.updated) {
console.warn(`Question backend id has changed from ${q.backendId} to ${response.updated}`);
}
} catch (error) { } catch (error) {
if (isAxiosCanceledError(error)) return; if (isAxiosCanceledError(error)) return;