Skip to main content
method OutgoingMessage.prototype.hasHeader
OutgoingMessage.prototype.hasHeader(name: string): boolean
Deprecated

Returns true if the header identified by name is currently set in the outgoing headers. The header name is case-insensitive.

const hasContentType = outgoingMessage.hasHeader('content-type');

Parameters

name: string

Return Type

boolean
Back to top