labelSchema.js
function getFirstProperty(fields) {
  return function(record) {
    for (var i = 0; i < fields.length; i++) {
      var fieldValue = record[fields[i]];

      if (!_.isEmpty(fieldValue)) {
        return fieldValue[0];
      }

    }

  };

}
function getFirstProperty(fields) {
  return function(record) {
    for (var i = 0; i < fields.length; i++) {
      var fieldValue = record[fields[i]];

      if (!_.isEmpty(fieldValue)) {
        return fieldValue[0];
      }

    }

  };

}
function getFirstProperty ( fields ) { return function ( record ) { for ( var i = 0 ; i < fields . length ; i ++ ) { var fieldValue = record [ fields [ i ] ] ; if ( ! _ . isEmpty ( fieldValue ) ) { return fieldValue [ 0 ] ; } } } ; }
find the first field of record that has a non-empty value that's not already in labelParts
find the first field of record that has a non - empty value that s not already in labelParts