From d147aae06610f4b690987fec3e2f26c761439ee8 Mon Sep 17 00:00:00 2001 From: Mm2PL Date: Thu, 3 Oct 2024 17:59:23 +0200 Subject: [PATCH] Unrelated: Fix file-relative require searcher --- src/controllers/plugins/LuaAPI.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controllers/plugins/LuaAPI.cpp b/src/controllers/plugins/LuaAPI.cpp index 9f0e73885..678e59061 100644 --- a/src/controllers/plugins/LuaAPI.cpp +++ b/src/controllers/plugins/LuaAPI.cpp @@ -284,7 +284,7 @@ int searcherAbsolute(lua_State *L) int searcherRelative(lua_State *L) { lua_Debug dbg; - lua_getstack(L, 1, &dbg); + lua_getstack(L, 2, &dbg); lua_getinfo(L, "S", &dbg); auto currentFile = QString::fromUtf8(dbg.source, dbg.srclen); if (currentFile.startsWith("@"))