Apply DM Disable attribute to some commands
This commit is contained in:
parent
1e98b44cb7
commit
de408dbfd9
9 changed files with 18 additions and 0 deletions
|
@ -4,6 +4,7 @@ using System.Threading.Tasks;
|
|||
using Discord;
|
||||
using Discord.Commands;
|
||||
using Geekbot.net.Database;
|
||||
using Geekbot.net.Lib.CommandPreconditions;
|
||||
using Geekbot.net.Lib.ErrorHandling;
|
||||
using Geekbot.net.Lib.Extensions;
|
||||
using Geekbot.net.Lib.Levels;
|
||||
|
@ -25,6 +26,7 @@ namespace Geekbot.net.Commands.User
|
|||
|
||||
[Command("serverstats", RunMode = RunMode.Async)]
|
||||
[Summary("Show some info about the bot.")]
|
||||
[DisableInDirectMessage]
|
||||
public async Task GetInfo()
|
||||
{
|
||||
try
|
||||
|
|
|
@ -5,12 +5,14 @@ using Discord;
|
|||
using Discord.Commands;
|
||||
using Geekbot.net.Database;
|
||||
using Geekbot.net.Database.Models;
|
||||
using Geekbot.net.Lib.CommandPreconditions;
|
||||
using Geekbot.net.Lib.ErrorHandling;
|
||||
using Geekbot.net.Lib.Extensions;
|
||||
using Geekbot.net.Lib.Localization;
|
||||
|
||||
namespace Geekbot.net.Commands.User
|
||||
{
|
||||
[DisableInDirectMessage]
|
||||
public class Karma : ModuleBase
|
||||
{
|
||||
private readonly IErrorHandler _errorHandler;
|
||||
|
|
|
@ -5,6 +5,7 @@ using System.Text;
|
|||
using System.Threading.Tasks;
|
||||
using Discord.Commands;
|
||||
using Geekbot.net.Database;
|
||||
using Geekbot.net.Lib.CommandPreconditions;
|
||||
using Geekbot.net.Lib.Converters;
|
||||
using Geekbot.net.Lib.ErrorHandling;
|
||||
using Geekbot.net.Lib.Extensions;
|
||||
|
@ -33,6 +34,7 @@ namespace Geekbot.net.Commands.User.Ranking
|
|||
|
||||
[Command("rank", RunMode = RunMode.Async)]
|
||||
[Summary("get user top 10 in messages or karma")]
|
||||
[DisableInDirectMessage]
|
||||
public async Task RankCmd([Summary("type")] string typeUnformated = "messages", [Summary("amount")] int amount = 10)
|
||||
{
|
||||
try
|
||||
|
|
|
@ -5,6 +5,7 @@ using Discord;
|
|||
using Discord.Commands;
|
||||
using Geekbot.net.Database;
|
||||
using Geekbot.net.Lib.AlmostRedis;
|
||||
using Geekbot.net.Lib.CommandPreconditions;
|
||||
using Geekbot.net.Lib.ErrorHandling;
|
||||
using Geekbot.net.Lib.Extensions;
|
||||
using Geekbot.net.Lib.Levels;
|
||||
|
@ -28,6 +29,7 @@ namespace Geekbot.net.Commands.User
|
|||
|
||||
[Command("stats", RunMode = RunMode.Async)]
|
||||
[Summary("Get information about this user")]
|
||||
[DisableInDirectMessage]
|
||||
public async Task User([Summary("@someone")] IUser user = null)
|
||||
{
|
||||
try
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue