refactoring: links in a functions