Fixed bug introduced in last big cleanup