diff options
| author | Agando <roduccomm@gmail.com> | 2026-10-18 17:19:14 +0200 |
|---|---|---|
| committer | Agando <roduccomm@gmail.com> | 2026-10-18 17:19:14 +0200 |
| commit | 240e22bc2e4f6b67b032c0a317e456958520fe90 (patch) | |
| tree | ab2bd5ab291388dbbdf05386b891ac90f0dbe59a /modules/ext/course.js | |
| parent | 0cee9cbeaef95c4fbd0d6118eff6240aa2e4f282 (diff) | |
newOS4 v4.6.40: review fixes (bug diagnostics, trash tree, dir paste, stale capture, preview)
Diffstat (limited to 'modules/ext/course.js')
| -rw-r--r-- | modules/ext/course.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/modules/ext/course.js b/modules/ext/course.js index d3b96de..8c615ec 100644 --- a/modules/ext/course.js +++ b/modules/ext/course.js @@ -177,7 +177,10 @@ class CourseModule { if (cmd === 'course') return; // Only capture while an exercise is actually running. Capturing every command // swallowed all terminal output (pwd/help/version printed nothing). - if (!this._active || !this._active.lesson || !this._active.lesson.exercise) return; + if (!this._active || !this._active.lesson || !this._active.lesson.exercise) { + this._capOut = ''; // never let a previous command's output satisfy an output-check exercise + return; + } if (this._capActive) { try { this.terminal._popPrintCapture(); } catch (e) {} if (this._capOut) { try { this.terminal.print(this._capOut.replace(/\n+$/, '')); } catch (e) {} } |