Fixed bug in dt_remove_constant()