find first doc entry with url as canonical one, closes #62
Fix collapsed flag storage