From f1a742c45f97df1876c7cb73a638f141b89a1193 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Thu, 28 Sep 2023 15:49:03 -0500 Subject: [PATCH] jrItems - use if instead of select for possible nil --- addons/jr/fnc_compatibleItems.sqf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/jr/fnc_compatibleItems.sqf b/addons/jr/fnc_compatibleItems.sqf index afe9556b0..fb2db72d4 100644 --- a/addons/jr/fnc_compatibleItems.sqf +++ b/addons/jr/fnc_compatibleItems.sqf @@ -52,7 +52,7 @@ if (isNil QGVAR(namespace)) then { }; // Get cached result, if it exists -private _cachekey = format ["%1#%2", _weapon, ["all", _typefilter] select _typeFilterExists]; +private _cachekey = format ["%1#%2", _weapon, if (_typeFilterExists) then {_typefilter} else {"all"} ]; private _compatibleItems = GVAR(namespace) get _cachekey; if (!isNil "_compatibleItems") exitWith {