This should be $item instead of $entity