     sel = class_id: class_id
     if class_id is ""
         sel = {}
-    
+
     return _(Offline.smart.assignments().find(sel).fetch()).chain()
            .sortBy((obj) -> new Date(obj.due).getTime())
            .sortBy("done")
            .groupBy("done")
            .pairs()
-           .map(([truthiness, list]) -> _.sortBy(list, (obj) -> 
+           .map(([truthiness, list]) -> _.sortBy(list, (obj) ->
                 if truthiness is "true"
                     Math.abs(DateOMatic.msDifferential(new Date(obj.due)))
                 else

        Session.set "editing_itemname", this._id
        Deps.flush() # update DOM before focus
        activateInput(tmpl.find("#assignment-input"))
    
    "dblclick abbr": (evt, tmpl) ->
        Session.set "editing_due_date", @_id
        Deps.flush()

loadIntercom = (force = no) ->
    return Meteor.setTimeout((-> loadIntercomActual(force)), 250)

Meteor.startup ->
    Backbone.history.start pushState: true
    Meteor.call "hash", (error, user_hash) ->
        window.intercomSettings =
            # TODO: The current logged in user's email address.
