Skip to content

Strict-Transport-Security middleware should throw, not warn, when misspelling "includeSubDomains" option #462

@EvanHahn

Description

@EvanHahn

This should throw instead:

if ("includeSubdomains" in options) {
console.warn(
'Strict-Transport-Security middleware should use `includeSubDomains` instead of `includeSubdomains`. (The correct one has an uppercase "D".)',
);
}

To fix this, we should:

  1. Update these lines to throw, not warn.
  2. Fix the tests.

This change should be opened against the v8.0.0 branch, not main.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions