function getSpreadSheet_(fileName, objFolder) {

  let files = objFolder.getFilesByName(fileName);

  while (files.hasNext()) {
    let file = files.next();
    let fileId = file.getId();

    const existingSpreadsheet = SpreadsheetApp.openById(fileId);
    return existingSpreadsheet;
  }

  // If application destination spreadsheet is missing, creates a new sample version.
  const folderAppPrimary = getApplicationFolder_(APP_FOLDER);
  const sampleSheet = setupPrimarySpreadsheet_(folderAppPrimary);
  return sampleSheet;
}
Gets application destination spreadsheet from a given folder
Returns new sample version if orignal is not found. 

@param {string} fileName - Name of the file to test for.
@param {object} objFolder - Folder object in which to search.
@return {object} Spreadsheet object.