fix: load more close relays to allow for duplicate results
This commit is contained in:
parent
4ec40984d6
commit
0a42894a6f
@ -142,9 +142,13 @@ public class RedisStore
|
||||
{
|
||||
var ret = new Dictionary<Uri, RelayDistance>();
|
||||
var geoRelays =
|
||||
await _database.GeoSearchAsync(RelayPositionKey(), lon, lat, new GeoSearchCircle(radius), count);
|
||||
await _database.GeoSearchAsync(RelayPositionKey(), lon, lat, new GeoSearchCircle(radius), count * 2);
|
||||
foreach (var gr in geoRelays)
|
||||
{
|
||||
if (ret.Count == count)
|
||||
{
|
||||
break;
|
||||
}
|
||||
var id = ((string)gr.Member!).Split('\x1');
|
||||
var u = new Uri(id[0]);
|
||||
var info = await GetRelay(u);
|
||||
|
Loading…
x
Reference in New Issue
Block a user