We are getting the following error when executing Hosted Functions app:
<html> <head><title>502 Bad Gateway</title></head> <body bgcolor="white"> <center><h1>502 Bad Gateway</h1></center> <hr><center>nginx/1.11.10</center> </body> </html>
Solved! Go to Solution.
Error: Route.get() requires a callback function but got a [object Undefined] at Route.(anonymous function) [as get] (/node_modules/express/lib/router/route.js:202:15) at Function.proto.(anonymous function) [as get] (/node_modules/express/lib/router/index.js:510:19) at Object.<anonymous> (/build/routes.js:19:8) at Module._compile (module.js:643:30) at Object.Module._extensions..js (module.js:654:10) at Module.load (module.js:556:32) at tryModuleLoad (module.js:499:12) at Function.Module._load (module.js:491:3) at Module.require (module.js:587:17) at require (internal/module.js:11:18) at Object.<anonymous> (/build/app.js:8:16) at Module._compile (module.js:643:30) at Object.Module._extensions..js (module.js:654:10) at Module.load (module.js:556:32) at tryModuleLoad (module.js:499:12) at Function.Module._load (module.js:491:3) at Function.Module.runMain (module.js:684:10) at startup (bootstrap_node.js:187:16) at bootstrap_node.js:608:3
This resolved the issue.