#pragma once #include #include #include #include "../bundle.hpp" #include "../commands/command.hpp" #include "../commands/response_error.hpp" namespace bot { namespace mod { class Help : public command::Command { std::string get_name() const override { return "help"; } std::variant, std::string> run( const InstanceBundle &bundle, const command::Request &request) const override { if (!bundle.configuration.url.help.has_value()) { throw ResponseException( request, bundle.localization); } return bundle.localization .get_formatted_line(request, loc::LineId::HelpResponse, {*bundle.configuration.url.help}) .value(); } }; } }