Fixes bad entity_reference definition.