Boa Tarde,
Tive esse erro ao efetuar a refatoração no metodo de conexão de BD. Alguem já passou por esse problema?
TypeError: connectionFactory is not a function
at C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\app\routes\produtos.js:7:19
at Layer.handle [as handle_request] (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\layer.js:95:5)
at next (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\route.js:137:13)
at Route.dispatch (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\route.js:112:3)
at Layer.handle [as handle_request] (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\layer.js:95:5)
at C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\index.js:281:22
at Function.process_params (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\index.js:335:12)
at next (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\index.js:275:10)
at expressInit (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\middleware\init.js:40:5)
at Layer.handle [as handle_request] (C:\Users\Peterson\Documents\Projetos\Alura\Node\casadocodigo\node_modules\express\lib\router\layer.js:95:5)