diff --git a/src/module/timer/timer.cpp b/src/module/timer/timer.cpp index 82004d0..140c5f2 100644 --- a/src/module/timer/timer.cpp +++ b/src/module/timer/timer.cpp @@ -14,20 +14,20 @@ namespace program_options = boost::program_options; namespace chrono = std::chrono; namespace Module { - const std::string Timer::Info::MODULE_NAME{"Timer"}; - const std::string Timer::Info::COMMAND{"timer"}; - const std::string Timer::Info::COMMAND_DESCRIPTION{"set timer"}; + const std::string Timer::MODULE_NAME{"Timer"}; + const std::string Timer::COMMAND{"timer"}; + const std::string Timer::COMMAND_DESCRIPTION{"set timer"}; Timer::Timer() : - ModuleBase(Info::MODULE_NAME), + ModuleBase(MODULE_NAME), SlashCommandProcessorBase() {} void Timer::InitializeAppCommand() { SleepyDiscord::AppCommand::Option appCommand; - appCommand.name = Info::COMMAND; - appCommand.description = Info::COMMAND_DESCRIPTION; + appCommand.name = COMMAND; + appCommand.description = COMMAND_DESCRIPTION; SleepyDiscord::AppCommand::Option duration; duration.name = "duration"; diff --git a/src/module/timer/timer.h b/src/module/timer/timer.h index a8f7414..6be8501 100644 --- a/src/module/timer/timer.h +++ b/src/module/timer/timer.h @@ -7,11 +7,9 @@ namespace Module { class Timer : public ModuleBase , public SlashCommandProcessorBase{ private: public: - struct Info { - const static std::string MODULE_NAME; - const static std::string COMMAND; - const static std::string COMMAND_DESCRIPTION; - }; + const static std::string MODULE_NAME; + const static std::string COMMAND; + const static std::string COMMAND_DESCRIPTION; Timer(); void InteractionHandler(SleepyDiscord::Interaction& interaction) override; void InitializeAppCommand() override; diff --git a/src/module/urlshortening/URLShortening.cpp b/src/module/urlshortening/URLShortening.cpp index 978347f..33ced7c 100644 --- a/src/module/urlshortening/URLShortening.cpp +++ b/src/module/urlshortening/URLShortening.cpp @@ -12,18 +12,18 @@ namespace program_options = boost::program_options; namespace Module { - const std::string URLShortening::Info::MODULE_NAME{"URLShortening"}; - const std::string URLShortening::Info::COMMAND{"url"}; - const std::string URLShortening::Info::DESCRIPTION{ "Shorten specific URLs" }; + const std::string URLShortening::MODULE_NAME{"URLShortening"}; + const std::string URLShortening::COMMAND{"url"}; + const std::string URLShortening::DESCRIPTION{ "Shorten specific URLs" }; URLShortening::URLShortening() : - ModuleBase(Info::MODULE_NAME) + ModuleBase(MODULE_NAME) {} void URLShortening::InitializeAppCommand() { SleepyDiscord::AppCommand::Option appCommand; - appCommand.name = Info::COMMAND; - appCommand.description = Info::DESCRIPTION; + appCommand.name = COMMAND; + appCommand.description = DESCRIPTION; SleepyDiscord::AppCommand::Option url; url.name = "url"; diff --git a/src/module/urlshortening/URLShortening.h b/src/module/urlshortening/URLShortening.h index fda6d5a..91b9608 100644 --- a/src/module/urlshortening/URLShortening.h +++ b/src/module/urlshortening/URLShortening.h @@ -7,11 +7,10 @@ namespace Module { private: std::string ShortenAmazonURL(const std::string& url); public: - struct Info { - const static std::string MODULE_NAME; - const static std::string COMMAND; - const static std::string DESCRIPTION; - }; + //constants + const static std::string MODULE_NAME; + const static std::string COMMAND; + const static std::string DESCRIPTION; URLShortening(); void InteractionHandler(SleepyDiscord::Interaction& interaction) override; void InitializeAppCommand() override;