Skip to content

Commit

Permalink
fix: cast falsy servername to null to avoid falsy inequality (nodejs#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ronag authored Jul 31, 2024
1 parent 69825dc commit 9bc9b44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/core/request.js
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ class Request {

validateHandler(handler, method, upgrade)

this.servername = servername || getServerName(this.host)
this.servername = servername || getServerName(this.host) || null

this[kHandler] = handler

Expand Down

0 comments on commit 9bc9b44

Please sign in to comment.