Cleanup of Relationship type encoder