You are here

function crumbs_EntityPlugin_Field_UserReference::fieldFindCandidate in Crumbs, the Breadcrumbs suite 7.2

Parameters

array $items:

Return value

string

Overrides crumbs_EntityPlugin_Field_Abstract::fieldFindCandidate

File

lib/EntityPlugin/Field/UserReference.php, line 8

Class

crumbs_EntityPlugin_Field_UserReference

Code

function fieldFindCandidate(array $items) {
  foreach ($items as $item) {
    if (1 && !empty($item['uid']) && ($target_user = user_load($item['uid'])) && ($uri = entity_uri('user', $target_user))) {
      return $uri['path'];
    }
  }
  return NULL;
}