MCPcopy Index your code
hub / github.com/freeCodeCamp/freeCodeCamp / normalizeSurveys

Function normalizeSurveys

api/src/utils/normalize.ts:219–226  ·  view source on GitHub ↗
(
  surveyResults: Survey[]
)

Source from the content-addressed store, hash-verified

217 * @returns The input without the id and userid.
218 */
219export const normalizeSurveys = (
220 surveyResults: Survey[]
221): NormalizedSurvey[] => {
222 return surveyResults.map(survey => {
223 const { title, responses } = survey;
224 return { title, responses };
225 });
226};
227
228/**
229 * Replace null flags with false.

Callers 1

getSessionUserHandlerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected