From c0d65f7f381f3e73c14170dd1294aac18a143d8a Mon Sep 17 00:00:00 2001 From: Gabriel Tofvesson Date: Sat, 30 Nov 2024 00:00:18 +0100 Subject: [PATCH] Update debugger --- storage/itemstack.lua | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/storage/itemstack.lua b/storage/itemstack.lua index b3f356a..d9a92a4 100644 --- a/storage/itemstack.lua +++ b/storage/itemstack.lua @@ -8,12 +8,15 @@ local ItemStack = Sentinel:tag({}, Sentinel.ITEMSTACK) ItemStack.__index = ItemStack local function hookDebugger(context) - while true do - local errorCond = Debugger.debugREPL(function(retval) - Logger:error("->", retval) + local result, retval + repeat + result, retval = Debugger.debugREPL(function(r) + Logger:error("->", r) end, context) - Logger:error("x>", errorCond) - end + if not result then + Logger:error("x>", retval) + end + until result end function ItemStack:fromDetail(inv, detail, slot)