-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Zzz module interface to be more similar to http.Server interface
- Loading branch information
Andrew Vayanis
committed
Mar 25, 2013
1 parent
c2d1560
commit ec01f81
Showing
1 changed file
with
6 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,13 @@ | ||
/** | ||
* Zees Includes | ||
*/ | ||
var zeeServer = require("./server"); | ||
var ZzzServer = require("./server"); | ||
|
||
/** | ||
* Globals | ||
*/ | ||
var server; | ||
module.exports = { | ||
|
||
/** | ||
* Wrap http createServer so that we can dynamically | ||
* define requestHandler | ||
* @return {http.Server} | ||
*/ | ||
exports.createServer = function() { | ||
server = new ZeeServer(); | ||
return server; | ||
}; | ||
createServer : function() { | ||
return new ZzzServer(); | ||
}, | ||
|
||
/** | ||
* Provides interface to http.Server.listen | ||
* @return {void} | ||
*/ | ||
exports.listen = function() { | ||
server.listen.apply(server, arguments); | ||
Server : ZzzServer | ||
} |