force stash to a table when removing items

This commit is contained in:
Jim Shield
2025-04-29 02:37:47 +01:00
parent 1d588c4f41
commit 8f7f9bb009

View File

@@ -295,7 +295,9 @@ end
--- stashRemoveItem(currentItems, "playerStash", { iron = 2, wood = 5 }) --- stashRemoveItem(currentItems, "playerStash", { iron = 2, wood = 5 })
--- ``` --- ```
function stashRemoveItem(stashItems, stashName, items) function stashRemoveItem(stashItems, stashName, items)
if type(stashName) ~= "table" then
stashName = { stashName }
end
if isStarted(OXInv) then if isStarted(OXInv) then
for k, v in pairs(items) do for k, v in pairs(items) do
if type(stashName) == "table" then if type(stashName) == "table" then