refactored linkId to linkIds