extract method for finding active or latest gem in a list