Don't call 'FilesToRemove[0]' when the vector is empty, even to compute