 
   render: ->
     {isLaunching, defaultHeight} = @props
-    {height, isEnrollmentCodeValid, isEnrollmentTargetPast} = @state
+    {height, isEnrollmentCodeValid, isCoursePast} = @state
     user = @getUser()
-    isEnrolled =  user.isEnrolled(@props.collectionUUID, @props.enrollmentCode)
+    isEnrolled =  @isEnrolled()
     isLoggedIn = user.isLoggedIn()
 
     finePrint = if isEnrolled
-      if isEnrollmentTargetPast
+      if isCoursePast
         <SemesterIsPast {...@props}/>
       else
         <SwitchSections {...@props}/>


  setIsEnrollmentCodeValid: (eventChannel, data) ->
    if eventChannel.event is 'validated.failure'
      @setState(isEnrollmentTargetPast: includes(map(data, 'code'), 'course_ended'))
    else if eventChannel.event is 'validated.success'
      @props.setIsEnrollmentCodeValid?(true)
      @setState(isEnrollmentCodeValid: true)

  mixins: [UserStatusMixin]


    height: @getHeight()
    isEnrollmentCodeValid: false
    isEnrollmentTargetPast: false
    isCoursePast: false

  componentWillReceiveProps: (nextProps) ->
    @setState(height: @getHeight(nextProps)) if @props.isLaunching isnt nextProps.isLaunching
