During testing performance noticed that some part of code imply to be called twice. There is a place to improve performance.
$field_item->entity
Active
2.0
Code