function getFileWithVersion(data, specificationVersion) {
  let file;

  if (_.has(data[0], 'content')) {
    if (specificationVersion) {
      file = getFileByContentSpecificationVersion(data, specificationVersion);
    }
    else {
      file = getFileByContent(data);
    }
  }
  else if (_.has(data[0], 'fileName')) {
    if (specificationVersion) {
      file = getFileByFileNameSpecificVersion(data, specificationVersion);
    }
    else {
      file = getFileByFileName(data);
    }

  }
  return file;
}
When the user provides a folder, this function returns the file
that contains the version data
@param {array} data An array of file's paths
@param {string} specificationVersion the string of the desired version
@returns {object} object with hasDefinedVersion property and
The content of the file that contains the version data