Handle nil in options passed to sort_link, add test.