             preferences: {}
           })
           projectPreferences.update defaultPreferences
-          # projectPreferences.update 'preferences.mini_course_completed_at': now
           projectPreferences.save()
             .then =>
               @setState {slideToStart: slideToStart, projectPreferences: projectPreferences}
     else
-      slideToStart = 0
+      slideToStart = sessionStorage.getItem('minicourse_slide_last_seen') if sessionStorage.getItem('minicourse_slide_last_seen')?
+
       @setState {slideToStart}
   
   componentWillUnmount: ->
     if @state.projectPreferences?
-      if @state.projectPreferences.preferences.minicourses.slide_last_seen["id_#{@props.minicourse.id}"] < @props.minicourse.steps.length
-        nextSlideIndex = @state.projectPreferences.preferences.minicourses.slide_last_seen["id_#{@props.minicourse.id}"] + 1
-        @state.projectPreferences.update "preferences.minicourses.slide_last_seen.id_#{@props.minicourse.id}": nextSlideIndex
-        @state.projectPreferences.save()
+      @handleProjectPreferencesOnUnmount()
+    else
+      sessionStorage.setItem('minicourse_slide_last_seen', @state.slideToStart + 1) if @state.slideToStart < @props.minicourse.steps.length
   
   render: ->
     <StepThrough ref="stepThrough" className="tutorial-steps" defaultStep={@state.slideToStart}>

    slideToStart: 0
    projectPreferences: null

  componentDidMount: ->
    defaultPreferences = { "preferences.minicourses.opt_out.id_#{@props.minicourse.id}": false, "preferences.minicourses.slide_last_seen.id_#{@props.minicourse.id}": 0 }

    if @props.user?

          # There's no workflow tutorial and no project given.
          Promise.resolve()

    checkIfCompleted: (minicourse, project, user) ->
      if user?
        user.get 'project_preferences', project_id: project.id
          .catch =>
            []
          .then ([projectPreferences]) =>
            window.prefs = projectPreferences
            projectPreferences?.preferences?.minicourses?.completed_at?["id_#{minicourse.id}"]?
      else
        Promise.resolve completedThisSession[minicourse.id]?

    start: (minicourse, user) ->
      MiniCourseComponent = this
