Permalink
Browse files

Remove unnecessary indentations

  • Loading branch information...
1 parent e2a1663 commit 9be54f30cc0cfeb3851b9b5033db7d9b3345cdb5 @CrabDude committed Feb 12, 2013
Showing with 22 additions and 23 deletions.
  1. +22 −23 README.md
View
@@ -64,19 +64,18 @@ Basic Example
-------------
```javascript
-
- var trycatch = require("trycatch"),
- _ = require('underscore')._
-
- trycatch(function() {
- _.map(['Error 1', 'Error 2'], function foo(v) {
- setTimeout(function() {
- throw new Error(v)
- }, 10)
- })
- }, function(err) {
- console.log("Async error caught!\n", err.stack);
- });
+var trycatch = require("trycatch"),
+ _ = require('underscore')._
+
+ trycatch(function() {
+ _.map(['Error 1', 'Error 2'], function foo(v) {
+ setTimeout(function() {
+ throw new Error(v)
+ }, 10)
+ })
+}, function(err) {
+ console.log("Async error caught!\n", err.stack);
+});
```
#### Output
@@ -93,16 +92,16 @@ Returning 500s on Server Request
--------------------------------
```javascript
- http.createServer(function(req, res) {
- trycatch(function() {
- setTimeout(function() {
- throw new Error('Baloney!');
- }, 1000);
- }, function(err) {
- res.writeHead(500);
- res.end(err.stack);
- });
- }).listen(8000);
+http.createServer(function(req, res) {
+ trycatch(function() {
+ setTimeout(function() {
+ throw new Error('Baloney!');
+ }, 1000);
+ }, function(err) {
+ res.writeHead(500);
+ res.end(err.stack);
+ });
+}).listen(8000);
```
Visit http://localhost:8000 and get your 500.

0 comments on commit 9be54f3

Please sign in to comment.