Use GeebotBase in every command

This commit is contained in:
runebaas 2019-05-23 23:38:07 +02:00
parent 8d9c436cfc
commit 295a1d575d
No known key found for this signature in database
GPG key ID: 2677AF508D0300D6
38 changed files with 77 additions and 40 deletions

View file

@ -7,6 +7,7 @@ using Discord.Commands;
using Discord.WebSocket; using Discord.WebSocket;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Database.Models; using Geekbot.net.Database.Models;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -17,7 +18,7 @@ namespace Geekbot.net.Commands.Admin
[Group("admin")] [Group("admin")]
[RequireUserPermission(GuildPermission.Administrator)] [RequireUserPermission(GuildPermission.Administrator)]
[DisableInDirectMessage] [DisableInDirectMessage]
public class Admin : ModuleBase public class Admin : GeekbotBase
{ {
private readonly DiscordSocketClient _client; private readonly DiscordSocketClient _client;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -4,6 +4,7 @@ using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Discord.WebSocket; using Discord.WebSocket;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.UserRepository; using Geekbot.net.Lib.UserRepository;
@ -15,7 +16,7 @@ namespace Geekbot.net.Commands.Admin
[RequireUserPermission(GuildPermission.ManageMessages)] [RequireUserPermission(GuildPermission.ManageMessages)]
[RequireUserPermission(GuildPermission.ManageRoles)] [RequireUserPermission(GuildPermission.ManageRoles)]
[DisableInDirectMessage] [DisableInDirectMessage]
public class Mod : ModuleBase public class Mod : GeekbotBase
{ {
private readonly DiscordSocketClient _client; private readonly DiscordSocketClient _client;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -3,6 +3,7 @@ using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Discord.WebSocket; using Discord.WebSocket;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.GlobalSettings; using Geekbot.net.Lib.GlobalSettings;
using Geekbot.net.Lib.Logger; using Geekbot.net.Lib.Logger;
@ -12,7 +13,7 @@ namespace Geekbot.net.Commands.Admin.Owner
{ {
[Group("owner")] [Group("owner")]
[RequireOwner] [RequireOwner]
public class Owner : ModuleBase public class Owner : GeekbotBase
{ {
private readonly DiscordSocketClient _client; private readonly DiscordSocketClient _client;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -1,4 +1,4 @@
using System; using System;
using System.Linq; using System.Linq;
using System.Text; using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
@ -7,6 +7,7 @@ using Discord.Commands;
using Discord.Net; using Discord.Net;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Database.Models; using Geekbot.net.Database.Models;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -17,7 +18,7 @@ namespace Geekbot.net.Commands.Admin
{ {
[Group("role")] [Group("role")]
[DisableInDirectMessage] [DisableInDirectMessage]
public class Role : ModuleBase public class Role : GeekbotBase
{ {
private readonly DatabaseContext _database; private readonly DatabaseContext _database;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -3,13 +3,14 @@ using System.Linq;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
using PokeAPI; using PokeAPI;
namespace Geekbot.net.Commands.Games namespace Geekbot.net.Commands.Games
{ {
public class Pokedex : ModuleBase public class Pokedex : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -1,9 +1,10 @@
using System; using System;
using System.Linq; using System.Linq;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Database.Models; using Geekbot.net.Database.Models;
using Geekbot.net.Lib;
using Geekbot.net.Lib.AlmostRedis; using Geekbot.net.Lib.AlmostRedis;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -13,7 +14,7 @@ using StackExchange.Redis;
namespace Geekbot.net.Commands.Games namespace Geekbot.net.Commands.Games
{ {
public class Roll : ModuleBase public class Roll : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly IAlmostRedis _redis; private readonly IAlmostRedis _redis;

View file

@ -4,13 +4,14 @@ using System.Net;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.GlobalSettings; using Geekbot.net.Lib.GlobalSettings;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Integrations.Google namespace Geekbot.net.Commands.Integrations.Google
{ {
public class Google : ModuleBase public class Google : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly IGlobalSettings _globalSettings; private readonly IGlobalSettings _globalSettings;

View file

@ -4,6 +4,7 @@ using System.Linq;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.Converters; using Geekbot.net.Lib.Converters;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -11,7 +12,7 @@ using MtgApiManager.Lib.Service;
namespace Geekbot.net.Commands.Integrations namespace Geekbot.net.Commands.Integrations
{ {
public class MagicTheGathering : ModuleBase public class MagicTheGathering : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly IMtgManaConverter _manaConverter; private readonly IMtgManaConverter _manaConverter;

View file

@ -4,13 +4,14 @@ using System.Web;
using System.Xml; using System.Xml;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.Clients; using Geekbot.net.Lib.Clients;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
namespace Geekbot.net.Commands.Integrations namespace Geekbot.net.Commands.Integrations
{ {
public class Mal : ModuleBase public class Mal : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly IMalClient _malClient; private readonly IMalClient _malClient;

View file

@ -4,13 +4,14 @@ using System.Net.Http;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Integrations.UbranDictionary namespace Geekbot.net.Commands.Integrations.UbranDictionary
{ {
public class UrbanDictionary : ModuleBase public class UrbanDictionary : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -6,6 +6,7 @@ using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
using HtmlAgilityPack; using HtmlAgilityPack;
@ -14,7 +15,7 @@ using WikipediaApi.Page;
namespace Geekbot.net.Commands.Integrations namespace Geekbot.net.Commands.Integrations
{ {
public class Wikipedia : ModuleBase public class Wikipedia : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly IWikipediaClient _wikipediaClient; private readonly IWikipediaClient _wikipediaClient;

View file

@ -1,6 +1,7 @@
using System; using System;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.GlobalSettings; using Geekbot.net.Lib.GlobalSettings;
using Google.Apis.Services; using Google.Apis.Services;
@ -8,7 +9,7 @@ using Google.Apis.YouTube.v3;
namespace Geekbot.net.Commands.Integrations namespace Geekbot.net.Commands.Integrations
{ {
public class Youtube : ModuleBase public class Youtube : GeekbotBase
{ {
private readonly IGlobalSettings _globalSettings; private readonly IGlobalSettings _globalSettings;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -2,12 +2,13 @@ using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.RandomNumberGenerator; using Geekbot.net.Lib.RandomNumberGenerator;
namespace Geekbot.net.Commands.Randomness namespace Geekbot.net.Commands.Randomness
{ {
public class BenedictCumberbatchNameGenerator : ModuleBase public class BenedictCumberbatchNameGenerator : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly IRandomNumberGenerator _randomNumberGenerator; private readonly IRandomNumberGenerator _randomNumberGenerator;

View file

@ -3,12 +3,13 @@ using System.Net.Http;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Randomness.Cat namespace Geekbot.net.Commands.Randomness.Cat
{ {
public class Cat : ModuleBase public class Cat : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -3,12 +3,13 @@ using System.Collections.Generic;
using System.Text; using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Media; using Geekbot.net.Lib.Media;
namespace Geekbot.net.Commands.Randomness namespace Geekbot.net.Commands.Randomness
{ {
public class CheckEm : ModuleBase public class CheckEm : GeekbotBase
{ {
private readonly IMediaProvider _checkEmImages; private readonly IMediaProvider _checkEmImages;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -3,12 +3,13 @@ using System.Net.Http;
using System.Net.Http.Headers; using System.Net.Http.Headers;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Randomness.Chuck namespace Geekbot.net.Commands.Randomness.Chuck
{ {
public class ChuckNorrisJokes : ModuleBase public class ChuckNorrisJokes : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -3,12 +3,13 @@ using System.Net.Http;
using System.Net.Http.Headers; using System.Net.Http.Headers;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Randomness.Dad namespace Geekbot.net.Commands.Randomness.Dad
{ {
public class DadJokes : ModuleBase public class DadJokes : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -3,12 +3,13 @@ using System.Net.Http;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Randomness.Dog namespace Geekbot.net.Commands.Randomness.Dog
{ {
public class Dog : ModuleBase public class Dog : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -2,11 +2,12 @@
using System.Collections.Generic; using System.Collections.Generic;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
namespace Geekbot.net.Commands.Randomness namespace Geekbot.net.Commands.Randomness
{ {
public class EightBall : ModuleBase public class EightBall : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -1,10 +1,11 @@
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.Media; using Geekbot.net.Lib.Media;
namespace Geekbot.net.Commands.Randomness namespace Geekbot.net.Commands.Randomness
{ {
public class Fortune : ModuleBase public class Fortune : GeekbotBase
{ {
private readonly IFortunesProvider _fortunes; private readonly IFortunesProvider _fortunes;

View file

@ -2,11 +2,12 @@
using System.Net; using System.Net;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
namespace Geekbot.net.Commands.Randomness namespace Geekbot.net.Commands.Randomness
{ {
public class Gdq : ModuleBase public class Gdq : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -4,13 +4,14 @@ using System.Net.Http.Headers;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Commands.Randomness.Dad; using Geekbot.net.Commands.Randomness.Dad;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Microsoft.AspNetCore.Hosting.Internal; using Microsoft.AspNetCore.Hosting.Internal;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Randomness.Kanye namespace Geekbot.net.Commands.Randomness.Kanye
{ {
public class Kanye : ModuleBase public class Kanye : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -1,11 +1,12 @@
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.Media; using Geekbot.net.Lib.Media;
namespace Geekbot.net.Commands.Randomness namespace Geekbot.net.Commands.Randomness
{ {
public class RandomAnimals : ModuleBase public class RandomAnimals : GeekbotBase
{ {
private readonly IMediaProvider _mediaProvider; private readonly IMediaProvider _mediaProvider;

View file

@ -5,13 +5,14 @@ using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Database.Models; using Geekbot.net.Database.Models;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
using Geekbot.net.Lib.RandomNumberGenerator; using Geekbot.net.Lib.RandomNumberGenerator;
namespace Geekbot.net.Commands.Randomness namespace Geekbot.net.Commands.Randomness
{ {
public class Ship : ModuleBase public class Ship : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly IRandomNumberGenerator _randomNumberGenerator; private readonly IRandomNumberGenerator _randomNumberGenerator;

View file

@ -5,6 +5,7 @@ using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Database.Models; using Geekbot.net.Database.Models;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -15,7 +16,7 @@ namespace Geekbot.net.Commands.Rpg
{ {
[DisableInDirectMessage] [DisableInDirectMessage]
[Group("cookies")] [Group("cookies")]
public class Cookies : ModuleBase public class Cookies : GeekbotBase
{ {
private readonly DatabaseContext _database; private readonly DatabaseContext _database;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -4,6 +4,7 @@ using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -11,7 +12,7 @@ using Geekbot.net.Lib.Levels;
namespace Geekbot.net.Commands.User namespace Geekbot.net.Commands.User
{ {
public class GuildInfo : ModuleBase public class GuildInfo : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly DatabaseContext _database; private readonly DatabaseContext _database;

View file

@ -5,6 +5,7 @@ using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Database.Models; using Geekbot.net.Database.Models;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -13,7 +14,7 @@ using Geekbot.net.Lib.Localization;
namespace Geekbot.net.Commands.User namespace Geekbot.net.Commands.User
{ {
[DisableInDirectMessage] [DisableInDirectMessage]
public class Karma : ModuleBase public class Karma : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly DatabaseContext _database; private readonly DatabaseContext _database;

View file

@ -5,6 +5,7 @@ using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.Converters; using Geekbot.net.Lib.Converters;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
@ -15,7 +16,7 @@ using Geekbot.net.Lib.UserRepository;
namespace Geekbot.net.Commands.User.Ranking namespace Geekbot.net.Commands.User.Ranking
{ {
public class Rank : ModuleBase public class Rank : GeekbotBase
{ {
private readonly IEmojiConverter _emojiConverter; private readonly IEmojiConverter _emojiConverter;
private readonly IHighscoreManager _highscoreManager; private readonly IHighscoreManager _highscoreManager;

View file

@ -4,6 +4,7 @@ using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Lib;
using Geekbot.net.Lib.AlmostRedis; using Geekbot.net.Lib.AlmostRedis;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
@ -12,7 +13,7 @@ using Geekbot.net.Lib.Levels;
namespace Geekbot.net.Commands.User namespace Geekbot.net.Commands.User
{ {
public class Stats : ModuleBase public class Stats : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly ILevelCalc _levelCalc; private readonly ILevelCalc _levelCalc;

View file

@ -2,11 +2,12 @@
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
namespace Geekbot.net.Commands.Utils namespace Geekbot.net.Commands.Utils
{ {
public class AvatarGetter : ModuleBase public class AvatarGetter : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -7,12 +7,13 @@ using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Discord.WebSocket; using Discord.WebSocket;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Newtonsoft.Json; using Newtonsoft.Json;
namespace Geekbot.net.Commands.Utils.Changelog namespace Geekbot.net.Commands.Utils.Changelog
{ {
public class Changelog : ModuleBase public class Changelog : GeekbotBase
{ {
private readonly DiscordSocketClient _client; private readonly DiscordSocketClient _client;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -1,12 +1,13 @@
using System; using System;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Localization; using Geekbot.net.Lib.Localization;
namespace Geekbot.net.Commands.Utils namespace Geekbot.net.Commands.Utils
{ {
public class Choose : ModuleBase public class Choose : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly ITranslationHandler _translation; private readonly ITranslationHandler _translation;

View file

@ -4,11 +4,12 @@ using System.Linq;
using System.Text; using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.RandomNumberGenerator; using Geekbot.net.Lib.RandomNumberGenerator;
namespace Geekbot.net.Commands.Utils.Dice namespace Geekbot.net.Commands.Utils.Dice
{ {
public class Dice : ModuleBase public class Dice : GeekbotBase
{ {
private readonly IRandomNumberGenerator _randomNumberGenerator; private readonly IRandomNumberGenerator _randomNumberGenerator;

View file

@ -1,12 +1,13 @@
using System; using System;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.Converters; using Geekbot.net.Lib.Converters;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
namespace Geekbot.net.Commands.Utils namespace Geekbot.net.Commands.Utils
{ {
public class Emojify : ModuleBase public class Emojify : GeekbotBase
{ {
private readonly IEmojiConverter _emojiConverter; private readonly IEmojiConverter _emojiConverter;
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -3,11 +3,12 @@ using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord; using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
namespace Geekbot.net.Commands.Utils namespace Geekbot.net.Commands.Utils
{ {
public class Help : ModuleBase public class Help : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;

View file

@ -11,7 +11,7 @@ using Geekbot.net.Lib.Extensions;
namespace Geekbot.net.Commands.Utils namespace Geekbot.net.Commands.Utils
{ {
public class Info : ModuleBase public class Info : GeekbotBase
{ {
private readonly DiscordSocketClient _client; private readonly DiscordSocketClient _client;
private readonly CommandService _commands; private readonly CommandService _commands;

View file

@ -1,9 +1,10 @@
using System.Threading.Tasks; using System.Threading.Tasks;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Lib;
namespace Geekbot.net.Commands.Utils namespace Geekbot.net.Commands.Utils
{ {
public class Ping : ModuleBase public class Ping : GeekbotBase
{ {
[Command("👀", RunMode = RunMode.Async)] [Command("👀", RunMode = RunMode.Async)]
[Summary("Look at the bot.")] [Summary("Look at the bot.")]

View file

@ -5,6 +5,7 @@ using Discord;
using Discord.Commands; using Discord.Commands;
using Geekbot.net.Database; using Geekbot.net.Database;
using Geekbot.net.Database.Models; using Geekbot.net.Database.Models;
using Geekbot.net.Lib;
using Geekbot.net.Lib.CommandPreconditions; using Geekbot.net.Lib.CommandPreconditions;
using Geekbot.net.Lib.ErrorHandling; using Geekbot.net.Lib.ErrorHandling;
using Geekbot.net.Lib.Extensions; using Geekbot.net.Lib.Extensions;
@ -16,7 +17,7 @@ namespace Geekbot.net.Commands.Utils.Quote
{ {
[Group("quote")] [Group("quote")]
[DisableInDirectMessage] [DisableInDirectMessage]
public class Quote : ModuleBase public class Quote : GeekbotBase
{ {
private readonly IErrorHandler _errorHandler; private readonly IErrorHandler _errorHandler;
private readonly DatabaseContext _database; private readonly DatabaseContext _database;