       for term, selected of _this.selected
         if selected and not _this._termInResults(term, terms)
           _this.selected[term] = 0
-          _this.controller.removeFilter _this.name, term 
+          _this.controller.removeFilter _this.name, term
 
   _termInResults: (term, terms) ->
     for elem in terms

  constructor: (container, @name, options = {}) ->
    @selected = {}
    if not options.template
      template = '{{#if @index}}' + 
            '<hr class="df-separator">' +
            '{{/if}}' +
            '<div class="df-facets">'+


    if res.results
      # To make access to selected easier
      # we add it to each term
      for term in res.facets[@name].terms
        if @selected[term.term]
          term.selected = 1
        else
          term.selected = 0

      context = $.extend true,
        total_selected: totalSelected
        name: @name
        terms: res.facets[@name].terms,
        @extraContext || {}

      html = @template(context)
