mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-10 09:18:27 -04:00
DM send by the bot when being the target of a .give command will now once again contain amount.
This commit is contained in:
@@ -9,6 +9,10 @@ Experimental changelog. Mostly based on [keepachangelog](https://keepachangelog.
|
|||||||
|
|
||||||
- `.clubdesc <msg>` will now have a nicer response
|
- `.clubdesc <msg>` will now have a nicer response
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- `.give` DM will once again show an amount
|
||||||
|
|
||||||
## [4.1.4] - 06-05-2022
|
## [4.1.4] - 06-05-2022
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
|
@@ -363,7 +363,7 @@ public partial class Gambling : GamblingModule<GamblingService>
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!await _cs.TransferAsync(_eb, ctx.User, receiver, amount, msg))
|
if (!await _cs.TransferAsync(_eb, ctx.User, receiver, amount, msg, N(amount)))
|
||||||
{
|
{
|
||||||
await ReplyErrorLocalizedAsync(strs.not_enough(CurrencySign));
|
await ReplyErrorLocalizedAsync(strs.not_enough(CurrencySign));
|
||||||
return;
|
return;
|
||||||
|
@@ -17,7 +17,8 @@ public static class CurrencyServiceExtensions
|
|||||||
IUser from,
|
IUser from,
|
||||||
IUser to,
|
IUser to,
|
||||||
long amount,
|
long amount,
|
||||||
string? note)
|
string? note,
|
||||||
|
string formattedAmount)
|
||||||
{
|
{
|
||||||
var fromWallet = await cs.GetWalletAsync(from.Id);
|
var fromWallet = await cs.GetWalletAsync(from.Id);
|
||||||
var toWallet = await cs.GetWalletAsync(to.Id);
|
var toWallet = await cs.GetWalletAsync(to.Id);
|
||||||
@@ -28,8 +29,8 @@ public static class CurrencyServiceExtensions
|
|||||||
{
|
{
|
||||||
await to.SendConfirmAsync(ebs,
|
await to.SendConfirmAsync(ebs,
|
||||||
string.IsNullOrWhiteSpace(note)
|
string.IsNullOrWhiteSpace(note)
|
||||||
? $"Gift from {from}"
|
? $"Received {formattedAmount} from {from} "
|
||||||
: $"Gift from {from}: {note}");
|
: $"Received {formattedAmount} from {from}: {note}");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user