Make sure the factory is released when releasing the component.