Corrected the use of factories.