Permalink
Browse files

Add getter to avoid exposing _app for Manhattan use.

  • Loading branch information...
1 parent fac46b0 commit a41580feb794d3e75c8f4aefe03496a070d1b866 @mojit0 committed Oct 12, 2012
Showing with 9 additions and 0 deletions.
  1. +9 −0 lib/mojito.js
View
@@ -456,6 +456,15 @@ MojitoServer.prototype.close = function() {
/**
+ * Returns the instance of http.Server (or a subtype) which is the true server.
+ * @return {http.Server} The node.js http.Server (or subtype) instance.
+ */
+MojitoServer.prototype.getHttpServer = function() {
+ return this._app;
+};
+
+
+/**
* Invokes a callback function with the content of the requested url.
* @param {string} url A url to fetch.
* @param {{host: string, port: number, method: string}|function} opts A list of

0 comments on commit a41580f

Please sign in to comment.