<commit_before>window.SearchResultView = Backbone.CollectionView.extend({
  tagName: "div",
  className: "search-results",
  _loading: true,
  _page: 1,
  views: {},
  _previousLength: 0,

  initialize: function(options) {
    this.useTemplate("search_results", "_search_results");

    var self = this;

    this.collection.bind('add', this.addSearchResultItem, this);
    this.collection.bind('reset', this.resetSearchResultItems, this);

    this.$el.html(Mustache.to_html(this.tmpl, {}, this.partials));
    this.bindScroll();
  },

  render: function() {
    if (this.collection.length > 0) {
      this.resetSearchResultItems();
    }

    return this;
  },

  addSearchResultItem: function(search_result_item) {
    var view = new SearchResultItemView({
      model: search_result_item
    });
<commit_msg>Fixed issue #79<commit_after>window.SearchResultView = Backbone.CollectionView.extend({
  tagName: "div",
  className: "search-results",
  _loading: true,
  _page: 1,
  views: {},
  _previousLength: 0,

  initialize: function(options) {
    this.useTemplate("search_results", "_search_results");

    var self = this;

    this.collection.bind('add', this.addSearchResultItem, this);
    this.collection.bind('reset', this.resetSearchResultItems, this);

    this.$el.html(Mustache.to_html(this.tmpl, {}, this.partials));
    this.bindScroll();
  },

  render: function() {
    this.resetSearchResultItems();

    return this;
  },

  addSearchResultItem: function(search_result_item) {
    var view = new SearchResultItemView({
      model: search_result_item
    });

{'fraction_non_alphanumeric': 0.1390644753476612, 'fraction_numerical': 0.004424778761061947, 'mean_word_length': 4.057507987220447, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4247747', 'n_tokens_mistral': 512, 'n_tokens_neox': 491, 'n_words': 89}