Skip to content

Commit

Permalink
Merge pull request #40 from javieraviles/bugfix/issues36and39
Browse files Browse the repository at this point in the history
Bugfix/issues36and39
  • Loading branch information
javieraviles authored Jul 16, 2019
2 parents 8cbb97f + 9072aa5 commit 34d3eb0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -364,6 +364,11 @@ To install or update these dependencies you can use `npm install` or `npm update

## Changelog

### 1.4.2
- Fix -> `npm run watch-server` is now working properly live-reloading changes in the code [Issue 39](https://github.com/javieraviles/node-typescript-koa-rest/issues/39).
- Fix -> Logging levels were not correctly mapped. Thanks to @atamano for the PR [Pull Request 35](https://github.com/javieraviles/node-typescript-koa-rest/pull/35)
- Some code leftovers removed

### 1.4.1
- Fix -> After updating winston to 3.0.0, it was throwing an error when logging errors into file
- Fix -> Config in config.ts wasn't implementing IConfig interface
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "node-typescript-koa-rest",
"version": "1.4.1",
"version": "1.4.2",
"description": "API REST using NodeJS and KOA framework, typescript. TypeORM for SQL with class-validators. Middlewares JWT, CORS, Winston Logger.",
"main": "dist/server.js",
"scripts": {
"watch-server": "nodemon --watch 'src/**/*' -e ts,tsx --exec ts-node src/server.ts",
"watch-server": "nodemon --watch src -e ts,tsx --exec ts-node src/server.ts",
"build-ts": "tsc",
"copy-static-assets": "ts-node copyStaticAssets.ts",
"tslint": "tslint -c tslint.json -p tsconfig.json",
Expand Down
4 changes: 0 additions & 4 deletions src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import * as bodyParser from 'koa-bodyparser';
import * as helmet from 'koa-helmet';
import * as cors from '@koa/cors';
import * as winston from 'winston';
import * as dotenv from 'dotenv';
import { createConnection } from 'typeorm';
import 'reflect-metadata';
import * as PostgressConnectionStringParser from 'pg-connection-string';
Expand All @@ -13,9 +12,6 @@ import { logger } from './logging';
import { config } from './config';
import { router } from './routes';

// Load environment variables from .env file, where API keys and passwords are configured
dotenv.config({ path: '.env' });

// Get DB connection options from env variable
const connectionOptions = PostgressConnectionStringParser.parse(config.databaseUrl);

Expand Down

0 comments on commit 34d3eb0

Please sign in to comment.