lib/utils/yamlAstParser.js/constructPlainObject
const constructPlainObject = (ymlAstContent, branchObject) => {
  const newbranchObject = branchObject || {};
  if (ymlAstContent.mappings && _.isArray(ymlAstContent.mappings)) {
    _.forEach(ymlAstContent.mappings, v => {
      if (!v.value) {
        // no need to log twice, parseAST will log errors
        return;
      }

      if (v.key.kind === 0 && v.value.kind === 0) {
        newbranchObject[v.key.value] = v.value.value;
      } else if (v.key.kind === 0 && v.value.kind === 2) {
        newbranchObject[v.key.value] = constructPlainObject(v.value, {});
      } else if (v.key.kind === 0 && v.value.kind === 3) {
        const plainArray = [];
        _.forEach(v.value.items, c => {
          plainArray.push(c.value);
        });
        newbranchObject[v.key.value] = plainArray;
      }
    });
  }

  return newbranchObject;
};