Fix acceptance tests, use the correct method of getting redis key.

This commit is contained in:
Shane Kilkelly 2016-11-14 16:33:54 +00:00
parent b67a65ff6a
commit b212c00311

View file

@ -11,11 +11,11 @@ rclient = UserSessionsRedis.client()
module.exports = module.exports =
getUserSessions: (user, callback=(err, sessionsSet)->) -> getUserSessions: (user, callback=(err, sessionsSet)->) ->
rclient.smembers "UserSessions:{#{user._id}}", (err, result) -> rclient.smembers UserSessionsRedis.sessionSetKey(user), (err, result) ->
return callback(err, result) return callback(err, result)
clearUserSessions: (user, callback=(err)->) -> clearUserSessions: (user, callback=(err)->) ->
sessionSetKey = "UserSessions:{#{user._id}}" sessionSetKey = UserSessionsRedis.sessionSetKey(user)
rclient.smembers sessionSetKey, (err, sessionKeys) -> rclient.smembers sessionSetKey, (err, sessionKeys) ->
if err if err
return callback(err) return callback(err)