Add link_to_registration feature, refactoring