问题
redisClient.set('sessionKey', userSession, function(err){
console.log(err || 'sessionKey updated');
});
The above works.
But following does not update the existing session key.
redisClient.get(sessionKey, function(err, userSession){ // works fine
userSession = // some modification;
redisClient.set(sessionKey, userSession, function(err){
console.log(err || 'sessionKey updated');
});
});
I'm using localhost with redistogo thru heroku. There is no error. Even the console.log(err || 'sessionkey update'); prints
来源:https://stackoverflow.com/questions/20331355/redis-session-key-not-updating