UNPKG

dogstack

Version:

a popular-choice grab-bag framework for teams working on production web apps

18 lines (13 loc) 232 B
module.exports = normalizePort function normalizePort (val) { const port = parseInt(val, 10) if (isNaN(port)) { // named pipe return val } if (port >= 0) { // port number return port } return false }