<commit_before>class window.SubComments extends Backbone.Factlink.Collection
  model: SubComment

  initialize: (models, options) ->
    @parentModel = options.parentModel

    @on 'add', => @parentModel.set 'can_destroy?', false
    @on 'remove', => @parentModel.fetch if @length <= 0
    @on 'add remove reset', => @parentModel.set 'sub_comments_count', @length

  url: -> @parentModel.url() + '/sub_comments'<commit_msg>Fixed is_deletable in SubComments collection<commit_after>class window.SubComments extends Backbone.Factlink.Collection
  model: SubComment

  initialize: (models, options) ->
    @parentModel = options.parentModel

    @on 'add', => @parentModel.set 'is_deletable', false
    @on 'remove', => @parentModel.fetch if @length <= 0
    @on 'add remove reset', => @parentModel.set 'sub_comments_count', @length

  url: -> @parentModel.url() + '/sub_comments'
{'fraction_non_alphanumeric': 0.1402508551881414, 'fraction_numerical': 0.002280501710376283, 'mean_word_length': 4.664516129032258, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 13, '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': '7143636', 'n_tokens_mistral': 274, 'n_tokens_neox': 262, 'n_words': 67}