Fixing a bug with the factor enumeration tool