This commit is contained in:
luying
2021-10-15 16:03:37 +08:00
parent a6763f690d
commit 84b7334df1
6 changed files with 20 additions and 16 deletions
+1 -1
View File
@@ -400,7 +400,7 @@ export class Rank {
let key = this.keyName.getNameWithPlus(config.name);
if(config.isTimestamp) score = this.handleTimestamp(score, config.len);
if(config.reverse) {
let pow = Math.pow(10, config.len + 1);
let pow = Math.pow(10, config.len);
score = pow - 1 - score;
}
await redisClient().zaddAsync(key, score, this.composeFields(this.key, myId));