Skip to content

Latest commit

 

History

History
26 lines (19 loc) · 384 Bytes

req.protocol.md

File metadata and controls

26 lines (19 loc) · 384 Bytes

req.protocol

The protocol used to send this request (req).

Usage

req.protocol;

Example

switch (req.protocol) {
  case 'http':
    // this is an HTTP request
    break;
  case 'https':
    // this is a secure HTTPS request
    break;
}