Fix an error in remapping