Skip to content
This repository was archived by the owner on Dec 24, 2022. It is now read-only.

Commit 76554a5

Browse files
authored
Update ScanResult.cs
1 parent a4065ea commit 76554a5

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/ServiceStack.Redis/ScanResult.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,9 @@ public static Dictionary<string, double> AsItemsWithScores(this ScanResult resul
1616
for (var i = 0; i < result.Results.Count; i += 2)
1717
{
1818
var key = result.Results[i];
19-
var score = result.Results[i + 1].ToDouble();
19+
var score = double.Parse(result.Results[i + 1].FromUtf8Bytes(),
20+
NumberStyles.Float,
21+
CultureInfo.InvariantCulture);
2022
to[key.FromUtf8Bytes()] = score;
2123
}
2224
return to;
@@ -34,4 +36,4 @@ public static Dictionary<string, string> AsKeyValues(this ScanResult result)
3436
return to;
3537
}
3638
}
37-
}
39+
}

0 commit comments

Comments
 (0)