function turnStringToBoolean(formObj) {
  for (const key in formObj) {
    if (formObj[key] === 'true') {
      formObj[key] = true;
    } else if (formObj[key] === 'false') {
      formObj[key] = false;
    }
  }
  return formObj;
}
/**
 * Replaces the stringified booleans in the values of the obejct
 * with boolean values
 *
 * @param {Object} formObj JSON representation of the form object
 * @returns {Object} The formObj with booleans, instead of stringified booleans
 */
Replaces the stringified booleans in the values of the obejct
with boolean values

@param {Object} formObj JSON representation of the form object
@returns {Object} The formObj with booleans, instead of stringified booleans
Replaces the stringified booleans in the values of the obejct with boolean values @param { Object } formObj JSON representation of the form object @returns { Object } The formObj with booleans instead of stringified booleans
function turnStringToBoolean(formObj) {
  for (const key in formObj) {
    if (formObj[key] === 'true') {
      formObj[key] = true;
    } else if (formObj[key] === 'false') {
      formObj[key] = false;
    }
  }
  return formObj;
}
function turnStringToBoolean ( formObj ) { for ( const key in formObj ) { if ( formObj [ key ] === 'true' ) { formObj [ key ] = true ; } else if ( formObj [ key ] === 'false' ) { formObj [ key ] = false ; } } return formObj ; }
Replaces the stringified booleans in the values of the obejct
 with boolean values
Replaces the stringified booleans in the values of the obejct with boolean values