Right here is exactly the place to post about those type of caveat as it's very on topic with this part! You are right and I had forgotten about the ward / effusion.
However, simply restructuring the function this way:
Code
function precast(spell)
if spell.type ~= 'JobAbility' then
equip(sets.precast.casting)
end
if sets.ja[spell.name] then
equip(sets.ja[spell.name])
elseif sets.ws[spell.name] then
equip(sets.ws[spell.name])
end
end
Should keep the catch all spirit as regardless of the "sub directory ja" such as wards and effusion, they'll just be caught on by name with a set like sets.ja['Valiance'].
Explanation of the restructure: By ending the first
if checking for the "JobAbility" type with "end" and moving on completely with a new
if after instead of the previous "elseif", catching a set by spell name no longer require it to be a JA, it can now be anything as long as a matching set name exist. That's because the check is now independant of the result of the previous type check since we removed the "elseif" for a new if.