Skip to content

fix: correct typos in source comments - #246

Merged
UlisesGascon merged 1 commit into
expressjs:masterfrom
haimingZZ:fix/typos-in-comments
Oct 6, 2026
Merged

UlisesGascon merged 1 commit into
expressjs:masterfrom
haimingZZ:fix/typos-in-comments

Conversation

@haimingZZ

Copy link
Copy Markdown
Contributor

Summary

Fix two clear typos in the codebase:

  • index.js:49 — code comment // fall-though → // fall-through
  • scripts/version-history.js:19 — error message Missing placegolder version in HISTORY.md → Missing placeholder version in HISTORY.md

Why

Both are obvious misspellings. The README and test files already use the correct spellings (fall-through, placeholder) — these two locations were the only outliers I could find.

Diff

--- a/index.js
+++ b/index.js
@@ -46,7 +46,7 @@ function serveStatic (root, options) {
   // copy options object
   var opts = Object.create(options || null)
 
-  // fall-though
+  // fall-through
   var fallthrough = opts.fallthrough !== false
 
--- a/scripts/version-history.js
+++ b/scripts/version-history.js
@@ -16,7 +16,7 @@ if (!MD_HEADER_REGEXP.test(historyFileLines[1])) {
 }
 
 if (!VERSION_PLACEHOLDER_REGEXP.test(historyFileLines[0])) {
-  console.error('Missing placegolder version in HISTORY.md')
+  console.error('Missing placeholder version in HISTORY.md')
   process.exit(1)
 }

No functional change — comments and an error string only.

Checklist

  • Docs/contribution only
  • No tests broken (no code logic changed)
  • No new dependencies

- index.js: 'fall-though' -> 'fall-through' in code comment
- scripts/version-history.js: 'placegolder' -> 'placeholder' in error message

Both are obvious misspellings, no functional change.
@UlisesGascon UlisesGascon self-assigned this Oct 6, 2026
@UlisesGascon
UlisesGascon merged commit 109a299 into expressjs:master Oct 6, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants