mirror of
https://github.com/TeamOctolings/Octobot.git
synced 2025-04-29 18:49:53 +03:00
Bump Remora.Discord.Interactivity from 4.5.0 to 4.5.1 (#68)
Bumps Remora.Discord.Interactivity from 4.5.0 to 4.5.1. Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: Octol1ttle <l1ttleofficial@outlook.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Octol1ttle <l1ttleofficial@outlook.com>
This commit is contained in:
parent
f752ebf101
commit
abce09f26d
11 changed files with 38 additions and 40 deletions
|
@ -72,17 +72,17 @@ public class KickCommandGroup : CommandGroup {
|
|||
var currentUserResult = await _userApi.GetCurrentUserAsync(CancellationToken);
|
||||
if (!currentUserResult.IsDefined(out var currentUser))
|
||||
return Result.FromError(currentUserResult);
|
||||
var userResult = await _userApi.GetUserAsync(userId.Value, CancellationToken);
|
||||
var userResult = await _userApi.GetUserAsync(userId, CancellationToken);
|
||||
if (!userResult.IsDefined(out var user))
|
||||
return Result.FromError(userResult);
|
||||
var guildResult = await _guildApi.GetGuildAsync(guildId.Value, ct: CancellationToken);
|
||||
var guildResult = await _guildApi.GetGuildAsync(guildId, ct: CancellationToken);
|
||||
if (!guildResult.IsDefined(out var guild))
|
||||
return Result.FromError(guildResult);
|
||||
|
||||
var data = await _dataService.GetData(guildId.Value, CancellationToken);
|
||||
var data = await _dataService.GetData(guildId, CancellationToken);
|
||||
Messages.Culture = GuildSettings.Language.Get(data.Settings);
|
||||
|
||||
var memberResult = await _guildApi.GetGuildMemberAsync(guildId.Value, target.ID, CancellationToken);
|
||||
var memberResult = await _guildApi.GetGuildMemberAsync(guildId, target.ID, CancellationToken);
|
||||
if (!memberResult.IsSuccess) {
|
||||
var embed = new EmbedBuilder().WithSmallTitle(Messages.UserNotFoundShort, currentUser)
|
||||
.WithColour(ColorsList.Red).Build();
|
||||
|
@ -90,7 +90,7 @@ public class KickCommandGroup : CommandGroup {
|
|||
return await _feedbackService.SendContextualEmbedResultAsync(embed, CancellationToken);
|
||||
}
|
||||
|
||||
return await KickUserAsync(target, reason, guild, channelId.Value, data, user, currentUser, CancellationToken);
|
||||
return await KickUserAsync(target, reason, guild, channelId, data, user, currentUser, CancellationToken);
|
||||
}
|
||||
|
||||
private async Task<Result> KickUserAsync(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue