title: node.js connect-redis redis.get(key,callback) return null
body: <p>in connect-redis  to return session value use .get(sid, callback) 
   but it always return null so I think its not save in redis but I check it session save in redis correctly after investigation find problem is with Sid see  /connect-redis/lib/connect-redis.js </p>
  
  <pre><code>  RedisStore.prototype.get = function(sid, fn){
     sid =this.prefix + sid;
      debug('GET "%s"', sid);
  
      console.log('lib');
      console.log(sid);
  
      this.client.get( sid , function(err, data){
  
        if (err) return fn(err);
        if (!data) return fn(null,'');
        var result;
        data = data.toString();
        debug('GOT %s', data);
        try {
          result = JSON.parse(data); 
        } catch (err) {
          return fn(err);
        }
  
        return fn(null, result);
      });
    };
  </code></pre>
  
  <p>if I but sessionID as string it will return session </p>
  
  <pre><code>  RedisStore.prototype.get = function(sid, fn){
  
    //  sid =this.prefix + sid;
      debug('GET "%s"', sid);
  
      console.log('lib');
      console.log(sid);
  
      this.client.get( 'lweUw//EdbygbGr/2gAZt0kb' , function(err, data){
  
        if (err) return fn(err);
        if (!data) return fn(null,'');
        var result;
        data = data.toString();
        debug('GOT %s', data);
        try {
          result = JSON.parse(data); 
        } catch (err) {
          return fn(err);
        }
  
        return fn(null, result);
      });
    };
  </code></pre>
  
  <p>Note: </p>
  
  <p>typeof(sid) is string  even if  add qoute to sid  like this "\'sid\'"  it will return null</p>