diff --git a/lib/swagger-express/index.js b/lib/swagger-express/index.js index dfab0a04..85a23949 100644 --- a/lib/swagger-express/index.js +++ b/lib/swagger-express/index.js @@ -265,7 +265,7 @@ exports.init = function (app, opt) { generate(opt); // Serve up swagger ui static assets - var swHandler = express['static'](opt.swaggerUI); + var swHandler = express.static(opt.swaggerUI); // Serve up swagger ui interface. var swaggerURL = new RegExp('^'+ opt.swaggerURL +'(\/.*)?$');