Skip to content

Commit

Permalink
🐛 ATM we need the Error Messages.
Browse files Browse the repository at this point in the history
  • Loading branch information
LukvonStrom committed Feb 26, 2018
1 parent 37ff679 commit 30f35bb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "api",
"version": "1.10.1",
"version": "1.10.3",
"description": "REST API written in TypeScript using express and mysql",
"author": "designhub",
"contributors": [
Expand Down
14 changes: 7 additions & 7 deletions src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ import * as exphbs from 'express-handlebars';
import * as path from 'path';

// Error handler service
import { development as DevelopmentErrorHandler, production as ProductionErrorHandler } from './services/errorHandler';
import C = require('./config-rewrapper');
import { development as DevelopmentErrorHandler/*, production as ProductionErrorHandler */} from './services/errorHandler';
// import C = require('./config-rewrapper');
import { errors } from 'celebrate';

import topdesign_router from './routes/topdesign';
Expand Down Expand Up @@ -72,11 +72,11 @@ app.use((req: express.Request, res: express.Response, next: Function) => {

// development error handler - will print stacktrace
// production error handler - no stacktraces leaked to user
if (C.development) {
app.use(DevelopmentErrorHandler);
} else {
app.use(ProductionErrorHandler);
}
// if (C.development) {
app.use(DevelopmentErrorHandler);
// } else {
// app.use(ProductionErrorHandler);
// }
/*
if (process.env.CI) {
console.log('Config loaded:');
Expand Down

0 comments on commit 30f35bb

Please sign in to comment.