diff --git a/lib/server/route.js b/lib/server/route.js index fed61965..06f38c4e 100644 --- a/lib/server/route.js +++ b/lib/server/route.js @@ -94,7 +94,7 @@ isRead = lengthTmpl === lenthPath; if (typeof callback !== 'function') - throw(Error('callback should be function!')); + throw Error('callback should be function!'); if (isRead) { callback(); @@ -109,7 +109,7 @@ files.read(filesList, 'utf8', function(error, files) { if (error) - throw(error); + throw error; else Object.keys(files).forEach(function(path) { var name = paths[path]; @@ -129,13 +129,13 @@ var name, p, isAuth, isFS, path; if (!request) - throw(Error('request could not be empty!')); + throw Error('request could not be empty!'); if (!response) - throw(Error('response could not be empty!')); + throw Error('response could not be empty!'); if (typeof callback !== 'function') - throw(Error('callback should be function!')); + throw Error('callback should be function!'); name = ponse.getPathName(request); isAuth = RegExp('^(/auth|/auth/github)$').test(name);