We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a516d6e commit 18db357Copy full SHA for 18db357
1 file changed
docs/step.html
@@ -257,12 +257,12 @@
257
258
function initializeTaskListCheckboxes(stepId) {
259
const container = document.getElementById('markdown-content');
260
+ if (!container) return;
261
const checkboxes = container.querySelectorAll('input[type="checkbox"]');
262
if (checkboxes.length === 0) return;
263
264
const allState = readCheckboxState();
- const stepState = Array.isArray(allState[stepId]) ? allState[stepId] : [];
265
- allState[stepId] = stepState;
+ const stepState = Array.isArray(allState[stepId]) ? allState[stepId] : (allState[stepId] = []);
266
267
checkboxes.forEach((checkbox, index) => {
268
checkbox.disabled = false;
0 commit comments