[HELP] bad argument #1 to 'paris' (table expected, got nil)

whatever ?

Citizen.CreateThread(function()
	while true do
		Citizen.Wait(0)

		if IsControlJustReleased(0, 289) then
			if IsInputDisabled(0) and not isDead and not ESX.UI.Menu.IsOpen('default', 'es_extended', 'inventory') then
				ESX.ShowInventory()
			end
		end
	end
end)

here client/main.lua 450

What does ShowInventory do

ESX.ShowInventory = function()
	local playerPed = PlayerPedId()
	local elements, currentWeight = {}, 0

	for k,v in pairs(ESX.PlayerData.accounts) do
		if v.money > 0 then
			local formattedMoney = _U('locale_currency', ESX.Math.GroupDigits(v.money))
			local canDrop = v.name ~= 'bank'

			table.insert(elements, {
				label = ('%s: <span style="color:green;">%s</span>'):format(v.label, formattedMoney),
				count = v.money,
				type = 'item_account',
				value = v.name,
				usable = false,
				rare = false,
				canRemove = canDrop
			})
		end
	end

My guess is that this: ESX.PlayerData.accounts is nil

How can we fix the value that is returning nil as shown in the error?

I’m having this similar issue and I can’t figure out how to go about fixing the issue or what lines of code I’m missing to make the table not return nil or whatever is happening

Thank you so much been struggling here

how did you fix it?