Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

create-server

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

create-server - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

README.md

24

index.js

@@ -85,14 +85,6 @@ 'use strict';

switch (type) {
case 'http':
server = require('http').createServer();
break;
case 'https':
server = require('https').createServer(options);
break;
case 'spdy':
server = require('spdy').createServer(options);
break;
if ('http' === type) {
server = require('http').createServer();
} else {
server = require(type).createServer(options);
}

@@ -126,4 +118,6 @@

//
if (fn.request) server.on('request', fn.request);
if (fn.close) server.once('close', fn.close);
['request', 'upgrade', 'error'].forEach(function each(event) {
if (fn[event]) server.on('request', fn[event]);
});

@@ -135,3 +129,3 @@ //

if (options.listen !== false && fn.listening) {
if (options.listen !== false) {
listen(server, port, fn.listening);

@@ -159,3 +153,3 @@ }

[
'close', 'request', 'listening',
'close', 'request', 'listening', 'upgrade', 'error',
'http', 'https', 'spdy'

@@ -162,0 +156,0 @@ ].forEach(function each(name) {

{
"name": "create-server",
"version": "0.0.3",
"version": "0.0.4",
"description": "Create a pre-configured HTTP server",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
"test": "mocha $(find test -name '*.test.js')"
},

@@ -31,3 +31,9 @@ "repository": {

"connected": "0.0.x"
},
"devDependencies": {
"assume": "0.0.x",
"mocha": "1.20.x",
"pre-commit": "0.0.x",
"spdy": "1.26.x"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc