.lb will no longer show people with 0 currency, feathub#127

This commit is contained in:
Master Kwoth 2017-11-17 19:52:40 +01:00
parent ed239e32c3
commit b5a089dbc0

View File

@ -28,7 +28,7 @@ namespace NadekoBot.Core.Services.Database.Repositories.Impl
} }
public IEnumerable<Currency> GetTopRichest(int count, int skip = 0) => public IEnumerable<Currency> GetTopRichest(int count, int skip = 0) =>
_set.OrderByDescending(c => c.Amount).Skip(skip).Take(count).ToList(); _set.Where(c => c.Amount > 0).OrderByDescending(c => c.Amount).Skip(skip).Take(count).ToList();
public long GetUserCurrency(ulong userId) => public long GetUserCurrency(ulong userId) =>
GetOrCreate(userId).Amount; GetOrCreate(userId).Amount;