fix-scan-error

This commit is contained in:
yaziming
2020-07-07 14:26:24 +08:00
parent d6abbe7e08
commit 1ae5bf8f08

View File

@@ -125,9 +125,10 @@ func (r *Redis) HScan(collection string) (results []string, err error) {
if err != nil {
return results, err
}
results = append(results, items[1])
for i := 0; i < len(items); i += 2 {
cur := items[i+1]
results = append(results, cur)
}
if cursor == 0 {
break
}