fix missing versions in factory
small fix: use each instead of map