Browse Source

small code clean up

pull/1162/head
JustNrik GitHub 7 years ago
parent
commit
661d63836f
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 14 deletions
  1. +4
    -14
      src/Discord.Net.Commands/ModuleBase.cs

+ 4
- 14
src/Discord.Net.Commands/ModuleBase.cs View File

@@ -18,21 +18,11 @@ namespace Discord.Commands
/// <param name="isTTS">Specifies if Discord should read this message aloud using TTS</param> /// <param name="isTTS">Specifies if Discord should read this message aloud using TTS</param>
/// <param name="embed">An embed to be displayed alongside the message</param> /// <param name="embed">An embed to be displayed alongside the message</param>
protected virtual async Task<IUserMessage> ReplyAsync(string message = null, bool isTTS = false, Embed embed = null, RequestOptions options = null) protected virtual async Task<IUserMessage> ReplyAsync(string message = null, bool isTTS = false, Embed embed = null, RequestOptions options = null)
{
return await Context.Channel.SendMessageAsync(message, isTTS, embed, options).ConfigureAwait(false);
}

protected virtual void BeforeExecute(CommandInfo command)
{
}
=> await Context.Channel.SendMessageAsync(message, isTTS, embed, options).ConfigureAwait(false);


protected virtual void AfterExecute(CommandInfo command)
{
}

protected virtual void OnModuleBuilding(CommandService commandService, ModuleBuilder builder)
{
}
protected virtual void BeforeExecute(CommandInfo command) { }
protected virtual void AfterExecute(CommandInfo command) { }
protected virtual void OnModuleBuilding(CommandService commandService, ModuleBuilder builder) { }


//IModuleBase //IModuleBase
void IModuleBase.SetContext(ICommandContext context) void IModuleBase.SetContext(ICommandContext context)


Loading…
Cancel
Save