mirror of
https://github.com/Jetsparrow/karmabot.git
synced 2026-01-21 09:06:09 +03:00
awards fix
This commit is contained in:
parent
d95dae4ddb
commit
fd732d8719
@ -34,9 +34,9 @@ namespace JetKarmaBot.Commands
|
|||||||
where award.ToId == asker.Id
|
where award.ToId == asker.Id
|
||||||
group award by award.AwardTypeId into g
|
group award by award.AwardTypeId into g
|
||||||
select new { AwardTypeId = g.Key, Amount = g.Sum(x => x.Amount) };
|
select new { AwardTypeId = g.Key, Amount = g.Sum(x => x.Amount) };
|
||||||
|
var awardsByType = awardsQuery.ToList();
|
||||||
response = currentLocale["jetkarmabot.status.listalltext"] + "\n"
|
response = currentLocale["jetkarmabot.status.listalltext"] + "\n"
|
||||||
+ string.Join("\n", awardsQuery.Select(a => $" - {db.AwardTypes.Find(a.AwardTypeId).Symbol} {a.Amount}"));
|
+ string.Join("\n", awardsByType.Select(a => $" - {db.AwardTypes.Find(a.AwardTypeId).Symbol} {a.Amount}"));
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user