Skip to content

Commit 0ae8338

Browse files
committed
0.0.3
Simplify code.
1 parent 89bbed6 commit 0ae8338

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Because I copy the same code in all my projects.
1717

1818
~~~ javascript
1919
var fastHttp = require("fast-http"),
20-
port = process.argv[2] || 1337;
20+
port = 80;
2121

22-
httpServer = fastHttp(port).listen(parseInt(port, 10));
22+
httpServer = fastHttp(port);
2323
~~~

fast-http.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ function fastHttp (port) {
4141
});
4242
});
4343

44-
return httpServer;
44+
return httpServer.listen(parseInt(process.argv[2] || port, 10));
4545
}
4646

4747

package.json

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "fast-http",
3-
"version": "0.0.2",
3+
"version": "0.0.3",
44
"description": "Create a tiny web server which does not support the MVC pattern,for simple Node.js app.",
55
"main": "fast-http.js",
66
"engines": {
@@ -16,10 +16,16 @@
1616
"basic",
1717
"simple"
1818
],
19-
"author": "cedced19",
19+
"author": {
20+
"name": "cedced19"
21+
},
2022
"license": "MIT",
2123
"bugs": {
2224
"url": "https://github.com/cedced19/fast-http/issues"
2325
},
24-
"homepage": "https://github.com/cedced19/fast-http"
26+
"homepage": "https://github.com/cedced19/fast-http",
27+
"readme": "# Reverse String\n\n[![Build Status](https://travis-ci.org/cedced19/fast-http.svg)](https://travis-ci.org/cedced19/fast-http)\n\n## Installation\n\n```\nnpm install fast-http --save\n```\n\n## Usage\n\nCreate a tiny web server which does not support the MVC pattern,for simple Node.js app.\nBecause I copy the same code in all my projects.\n\n## How to use\n\n~~~ javascript\nvar fastHttp = require(\"fast-http\"),\n port = process.argv[2] || 1337;\n\nhttpServer = fastHttp(port).listen(parseInt(port, 10));\n~~~",
28+
"readmeFilename": "README.md",
29+
30+
"_from": "fast-http@^0.0.1"
2531
}

0 commit comments

Comments
 (0)