fix performance regression