MCPcopy Index your code
hub / github.com/codecombat/codecombat / onJoinClassroomError

Method onJoinClassroomError

app/views/courses/CoursesView.js:671–683  ·  view source on GitHub ↗
(classroom, jqxhr, options)

Source from the content-addressed store, hash-verified

669 }
670
671 onJoinClassroomError (classroom, jqxhr, options) {
672 this.state = null
673 if (jqxhr.status === 422) {
674 this.errorMessage = 'Please enter a code.'
675 } else if (jqxhr.status === 404) {
676 this.errorMessage = $.t('signup.classroom_not_found')
677 } else if (jqxhr.status === 403) {
678 this.errorMessage = $.t('signup.activation_code_used')
679 } else {
680 this.errorMessage = `${jqxhr.responseText}`
681 }
682 return this.renderSelectors('#join-class-form')
683 }
684
685 onJoinClassroomSuccess (newClassroom, data, options) {
686 this.state = null

Callers 1

joinClassMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected