Fix the factoring so it actually works.