Fix for deletion of relationships among entities