From d850f3f5112bc76f87b046003046a5783c5d97e6 Mon Sep 17 00:00:00 2001 From: Louis Cheung Date: Fri, 5 Jun 2015 10:19:55 -0400 Subject: [PATCH] Fix listing issues --- example/app.js | 5 ++++- example/routes.js | 6 +++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/example/app.js b/example/app.js index e2a41ff3..683fc0ae 100644 --- a/example/app.js +++ b/example/app.js @@ -12,7 +12,7 @@ swagger.init(app, { info: { title: 'Hello World', version: '1.0.0', - apis: ['./routes.js'], + apis: ['./routes.js'] } }); @@ -23,4 +23,7 @@ var server = app.listen(3000, function () { var port = server.address().port; console.log('Example app listening at http://%s:%s', host, port); + + // FIXME: This is here for testing. Remove when finished. + console.dir(swagger.swaggerObject); }); diff --git a/example/routes.js b/example/routes.js index 970b3043..78d0e57b 100644 --- a/example/routes.js +++ b/example/routes.js @@ -9,7 +9,7 @@ module.exports.setup = function (app) { /** * @swagger */ - app.get('/', rootHandler) + app.get('/', rootHandler); /** * @swagger @@ -35,11 +35,11 @@ module.exports.setup = function (app) { * dataType: string */ app.get('/login', loginHandler); -} +}; function rootHandler(req, res) { res.send('Hello World!'); -}); +} function loginHandler(req, res) { var user = {};