bugfix to generate-names