Do not try to get edit links for terms that do not exist

Resovles #217