Fix up config to comply with meta

Update
This commit is contained in:
2025-05-04 23:33:14 +02:00
parent e676d53e97
commit c1885ce76a
12 changed files with 89 additions and 76 deletions

View File

@@ -1,6 +1,5 @@
local addonname, shared = ...
local _, shared = ...
---@cast shared HeimdallShared
---@cast addonname string
local ModuleName = "Echoer"
---@diagnostic disable-next-line: missing-fields
@@ -44,11 +43,11 @@ function shared.Echoer.Init()
if Heimdall_Data.config.echoer.debug then
print(string.format("[%s] Found echo command in message: %s", ModuleName, msg))
end
local msg = string.sub(msg, string.len(Heimdall_Data.config.echoer.prefix) + 1)
local echomsg = string.sub(msg, string.len(Heimdall_Data.config.echoer.prefix) + 1)
if Heimdall_Data.config.echoer.debug then
print(string.format("[%s] Echoing message: %s", ModuleName, msg))
print(string.format("[%s] Echoing message: %s", ModuleName, echomsg))
end
SendChatMessage(msg, "SAY")
SendChatMessage(echomsg, "SAY")
elseif Heimdall_Data.config.echoer.debug then
print(string.format("[%s] Message does not start with echo prefix", ModuleName))
end