fix crash with invalid fluids