 # `TaskActions.loaded` or `TaskActions.FAILED`
 _ = require 'underscore'
 
-{apiHelper, IS_LOCAL, toParams} = require './helpers/api'
+{apiHelper, IS_LOCAL, toParams, onRequestError} = require './helpers/api'
 TimeHelper = require './helpers/time'
 {CurrentUserActions, CurrentUserStore} = require './flux/current-user'
 {CourseActions} = require './flux/course'


{NotificationActions, NotificationStore} = require './flux/notifications'

BOOTSTRAPED_STORES = {
  user:   CurrentUserActions.loaded
  courses: CourseListingActions.loaded

    url: "/api/notifications"
  , displayError: false

  CurrentUserActions.logout.addListener 'trigger', ->
    # Logging out programatically needs to be done via a form submission or follow redirects
    # $.ajax('/accounts/logout', {method: 'DELETE'})
