mirror of
https://github.com/Jetsparrow/karmabot.git
synced 2026-01-21 09:06:09 +03:00
Also filter for chat in /award
This commit is contained in:
parent
5c19869186
commit
8f31f9c809
@ -82,7 +82,7 @@ namespace JetKarmaBot.Commands
|
|||||||
: string.Format(currentLocale["jetkarmabot.award.revokemessage"], getLocalizedName(awardType, currentLocale), "@" + recipient.Username);
|
: string.Format(currentLocale["jetkarmabot.award.revokemessage"], getLocalizedName(awardType, currentLocale), "@" + recipient.Username);
|
||||||
|
|
||||||
var currentCount = db.Awards
|
var currentCount = db.Awards
|
||||||
.Where(aw => aw.ToId == recipient.Id && aw.AwardTypeId == awardType.AwardTypeId)
|
.Where(aw => aw.ToId == recipient.Id && aw.AwardTypeId == awardType.AwardTypeId && aw.ChatId == args.Message.Chat.Id)
|
||||||
.Sum(aw => aw.Amount);
|
.Sum(aw => aw.Amount);
|
||||||
|
|
||||||
var response = message + "\n" + String.Format(currentLocale["jetkarmabot.award.statustext"], "@" + recipient.Username, currentCount, awardType.Symbol);
|
var response = message + "\n" + String.Format(currentLocale["jetkarmabot.award.statustext"], "@" + recipient.Username, currentCount, awardType.Symbol);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user