From 7f179853026052bcb9411188d0fe3b07af4ad8cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ale=C5=A1=20Orel?= Date: Thu, 3 Dec 2020 23:23:58 +0100 Subject: [PATCH] Server addres port fix. --- server/server.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/server/server.ts b/server/server.ts index 21f8de2..de0c08c 100644 --- a/server/server.ts +++ b/server/server.ts @@ -1,9 +1,9 @@ import * as express from 'express'; -import {Application} from "express"; -import {getAllCourses, getCourseById} from "./get-courses.route"; -import {searchLessons} from "./search-lessons.route"; +import {Application} from 'express'; +import {getAllCourses, getCourseById} from './get-courses.route'; +import {searchLessons} from './search-lessons.route'; const app: Application = express(); @@ -18,8 +18,8 @@ app.route('/api/lessons').get(searchLessons); -const httpServer:any = app.listen(9000, () => { - console.log("HTTP REST API Server running at http://localhost:" + httpServer.address().port); +const httpServer = app.listen(9000, () => { + console.log('HTTP REST API Server running at http://localhost:' + httpServer.address()['port']); });