Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

296
Vistas
'TypeError: Cannot read property 'prototype' of undefined' Redis connections

I am trying to connect to a Redis Azure instance and I'm following the tutorial here Link. However I keep receiving this error

"TypeError: Cannot read property 'prototype' of undefined"

on this line

bluebird.promisifyAll(redis.RedisClient.prototype);

I am using nodeJS on VSCode. I have npm installed redis and bluebird. Any help would be appreciated, thank you!

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

"TypeError: Cannot read property 'prototype' of undefined"

1. Make sure to remove import response from { 'express' } which might be got imported by default in your action page.

2. You can refer to how proptotype works under promisifyAll

Class property is a property with a function value that has a non-empty .prototype object. Returns the input object. Note that the original methods on the object are not overwritten but new methods are created with the Async-suffix. For example, if you promisifyAll the node.js fs object use fs.statAsync to call the promisified stat method.

Promise.promisifyAll(require("redis"));

//Later on, all redis client instances have promise returning functions:

redisClient.hexistsAsync("myhash", "field").then(function(v) {

}).catch(function(e) {

});

Reference: TypeError: Cannot read property 'prototype' of undefined React Express and Promise.promisifyAll

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda