fix potential crash for a worksite TE that has no inventory (WTF?)