'fix' bug in reference lookup based on multiple possible reference paragraphs and reference paragraphs without any links at all