From 638622d66dbe58ff96b7d1c2c6ec4b040b27da6d Mon Sep 17 00:00:00 2001 From: ilotterytea Date: Mon, 1 Dec 2025 20:51:32 +0500 Subject: feat: switch for lua scripts --- bot/src/config.hpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'bot/src/config.hpp') diff --git a/bot/src/config.hpp b/bot/src/config.hpp index 1a09463..70491bd 100644 --- a/bot/src/config.hpp +++ b/bot/src/config.hpp @@ -3,6 +3,7 @@ #include #include #include +#include #define GET_DATABASE_CONNECTION_URL(c) \ "dbname = " + c.database.name + " user = " + c.database.user + \ @@ -63,6 +64,11 @@ namespace bot { int timeout = 60; }; + struct LuaConfiguration { + bool allow_arbitrary_scripts = false; + std::vector script_whitelist; + }; + struct Configuration { TwitchCredentialsConfiguration twitch_credentials; KickCredentialsConfiguration kick_credentials; @@ -72,6 +78,7 @@ namespace bot { UrlConfiguration url; TokenConfiguration tokens; RssConfiguration rss; + LuaConfiguration lua; sol::table as_lua_table(std::shared_ptr luaState) const; }; -- cgit v1.2.3