Hapi showing undefined variable inside handler
问题 I'm using Hapi.js for a project and a config variable that I'm passing to my handler is coming up as undefined when I call my route. What am I doing wrong? server.js var Hapi = require('hapi'); var server = new Hapi.Server('0.0.0.0', 8080); // passing this all the way to the handler var config = {'number': 1}; var routes = require('./routes')(config); server.route(routes); server.start(); routes.js var Home = require('../controllers/home'); module.exports = function(config) { var home = new