src/components/extractFields.js
function getPropertyValue(wofData, property) {

  if (wofData.properties.hasOwnProperty(property)) {

    // if the value is an array, return the first item
    if (wofData.properties[property] instanceof Array) {
      return wofData.properties[property][0];
    }

    // otherwise just return the value as is
    return wofData.properties[property];
  }
  return false;
}
function getPropertyValue(wofData, property) {

  if (wofData.properties.hasOwnProperty(property)) {

    // if the value is an array, return the first item
    if (wofData.properties[property] instanceof Array) {
      return wofData.properties[property][0];
    }

    // otherwise just return the value as is
    return wofData.properties[property];
  }
  return false;
}
function getPropertyValue ( wofData , property ) { if ( wofData . properties . hasOwnProperty ( property ) ) { // if the value is an array, return the first item if ( wofData . properties [ property ] instanceof Array ) { return wofData . properties [ property ] [ 0 ] ; } // otherwise just return the value as is return wofData . properties [ property ] ; } return false ; }
Get the string value of the property or false if not found

@param {object} wofData
@param {string} property
@returns {boolean|string}
Get the string value of the property or false if not found