UNPKG

waigo

Version:

Node.js ES6 framework for reactive, data-driven apps and APIs (Koa, RethinkDB)

23 lines (16 loc) 357 B
"use strict"; const waigo = global.waigo, Q = waigo.load('support/promise'); /** * Shutdown the HTTP server. * * @param {Object} App The application. */ module.exports = function*(App) { if (App.server) { App.logger.debug('Shutting down HTTP server'); yield Q.promisify(App.server.close, { context: App.server })(); } };