<commit_before>(() => {

  'use strict';

  let excludeURL = [];
  init();

  function init() {
    load();
    $('.exclude').children('.url').focus();

    $('.exclude').on('submit', function(event) {
      event.preventDefault();
      if ($(this).children('.url').val() === '') {
        if ($('.description').hasClass('has-error') === false) {
          $(this).children('.url').css('border', '1px solid red');
          $('.description').prepend('<div class="error-message"><strong>This field cannot be blank.</strong></div>');
          $('.error-message').css('color', 'red').css('margin-bottom', '10px');
          $('.description').addClass('has-error');
        }
        return false;
      }
      add($(this).children('.url'));
      location.reload();
    });

    $(document).on('click', '.delete', function() {
      let index = $(this).parent().children('.index').text() - 1;
      excludeURL.splice(index, 1);
      save();
      location.reload();
    });
  }

  function load() {
    chrome.storage.sync.get(function(storage) {
      excludeURL = storage.excludeURL;
      for (var i = 0; i < excludeURL.length; i++) {
        $('.exclude-url-list').append('<tr><td class="index">' + (i + 1) + '</td><td class="value">' + excludeURL[i] + '</td><td class="delete"><button type="button">Delete</button></td></tr>');
      }
    });
  }

  function add(url) {
    excludeURL.unshift(url.val());
    save();
  }

  function save() {
    chrome.storage.sync.set({excludeURL: excludeURL});
  }

})();<commit_msg>:bug: Fix first load at options<commit_after>(() => {

  'use strict';

  let excludeURL = [];
  init();

  function init() {
    load();
    $('.exclude').children('.url').focus();

    $('.exclude').on('submit', function(event) {
      event.preventDefault();
      if ($(this).children('.url').val() === '') {
        if ($('.description').hasClass('has-error') === false) {
          $(this).children('.url').css('border', '1px solid red');
          $('.description').prepend('<div class="error-message"><strong>This field cannot be blank.</strong></div>');
          $('.error-message').css('color', 'red').css('margin-bottom', '10px');
          $('.description').addClass('has-error');
        }
        return false;
      }
      add($(this).children('.url'));
      location.reload();
    });

    $(document).on('click', '.delete', function() {
      let index = $(this).parent().children('.index').text() - 1;
      excludeURL.splice(index, 1);
      save();
      location.reload();
    });
  }

  function load() {
    chrome.storage.sync.get(function(storage) {
      if (storage.excludeURL === undefined) {
        // create chrome storage variable: excludeURL
        save();
      }
      else {
        excludeURL = storage.excludeURL;
      }
      for (var i = 0; i < excludeURL.length; i++) {
        $('.exclude-url-list').append('<tr><td class="index">' + (i + 1) + '</td><td class="value">' + excludeURL[i] + '</td><td class="delete"><button type="button">Delete</button></td></tr>');
      }
    });
  }

  function add(url) {
    excludeURL.unshift(url.val());
    save();
  }

  function save() {
    chrome.storage.sync.set({excludeURL: excludeURL});
  }

})();
{'fraction_non_alphanumeric': 0.23873173764376748, 'fraction_numerical': 0.004351880634131178, 'mean_word_length': 2.7637426900584794, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 33, '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': '6465621', 'n_tokens_mistral': 1011, 'n_tokens_neox': 968, 'n_words': 171}