[enter image description here](https://i.stack.imgur.com/Sk8V7.[enter image description here](https://i.stack.imgur.com/cqnZu.png)pnenter image description hereg)
Please can some one help, i have attached 3 images of all code need for this issue
getting bad argument #1 to 'upper' (string expected, got nil) i have posted code below as well:
mf/src/client
local internalOpenWeaponLoadout = function(data)
local k,v = ESX.GetWeapon(data.name)
local categories = {}
local weapon = {
name = data.name:lower(),
label = data.label,
WeaponId = data.metadata.WeaponUniqueId,
components = {}
}
esx/commom/functions
function ESX.GetWeapon(weaponName)
weaponName = string.upper(weaponName)
for k,v in ipairs(Config.Weapons) do
if v.name == weaponName then
return k, v
end
end
end
I tried changing string to match weaponname 'lower'