MCPcopy Create free account
hub / github.com/codecombat/codecombat / orgKindString

Function orgKindString

app/core/utils.js:1574–1589  ·  view source on GitHub ↗
(kind, org = null)

Source from the content-addressed store, hash-verified

1572]
1573
1574const orgKindString = function (kind, org = null) {
1575 if ((kind === 'administrative-region') && ((org != null ? org.country : undefined) === 'US') && /^en/.test(me.get('preferredLanguage'))) { return 'State' }
1576 const key = {
1577 country: 'outcomes.country',
1578 'administrative-region': 'teachers_quote.state',
1579 'school-district': 'teachers_quote.district_label',
1580 'school-admin': 'outcomes.school_admin',
1581 'school-network': 'outcomes.school_network',
1582 'school-subnetwork': 'outcomes.school_subnetwork',
1583 school: 'teachers_quote.organization_label',
1584 teacher: 'courses.teacher',
1585 classroom: 'outcomes.classroom',
1586 student: 'courses.student',
1587 }[kind]
1588 return $.i18n.t(key)
1589}
1590
1591const getProduct = function () { if (isOzaria) { return OZARIA } else { return CODECOMBAT } }
1592

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected