Links::linkedTo() can return nullptrs if linked Components cannot be found in their Resource
- Imagine we have Resource "x" with Component "a" and Resource "y" with Component "b".
- Link Component "a" to Component "b".
- Remove Component "b" from Resource "y".
- Call a->linkedTo(). The returned set will contain a nullptr.
What happened? Links is calling Resource::find(ComponentPtr) and it is not checking that find() returns a non-null ComponentPtr.
This means that the burden is on the client of linkedTo() check each element of the returned PersistentObjectSet.