<commit_before>'use strict';

function saveOptions() {
  var token = document.getElementById('oauth_token').value;
  chrome.storage.sync.set({
    oauthToken: token
  }, function() {
    var status = document.getElementById('status');
    status.textContent = 'Options saved.';
    document.getElementById('oauth_token').value = '';
    setTimeout(function() {
      setTokenStatus(token);
    }, 750);
  });
}

function restoreOptions() {
  chrome.storage.sync.get({
    oauthToken: ''
  }, function(items) {
      setTokenStatus(items.oauthToken);
  });
}

function setTokenStatus(token) {
    var status = document.getElementById('status');
    
    if (token !== '') {
        status.textContent = 'An OAuth Token is present.  Enter a new one (or blank) to overwrite.';
    }
    else {
        status.textContent = '';
    }
}

document.addEventListener('DOMContentLoaded', restoreOptions);
document.getElementById('save').addEventListener('click',
    saveOptions);<commit_msg>remove warning<commit_after>'use strict';

function saveOptions() {
  var token = document.getElementById('oauth_token').value;
  chrome.storage.sync.set({
    oauthToken: token
  }, function() {
    var status = document.getElementById('status');
    status.textContent = 'Options saved.';
    document.getElementById('oauth_token').value = '';
    setTimeout(function() {
      setTokenStatus(token);
    }, 750);
  });
}

function restoreOptions() {
  chrome.storage.sync.get({
    oauthToken: ''
  }, function(items) {
      setTokenStatus(items.oauthToken);
  });
}

function setTokenStatus(token) {
    var status = document.getElementById('status');
    
    if (token !== '') {
        status.textContent = 'An OAuth Token is present.  Enter a new one (or blank) to overwrite.';
    }
    else {
        status.textContent = '';
    }
}

if (document) {
  document.addEventListener('DOMContentLoaded', restoreOptions);
  document.getElementById('save').addEventListener('click',
      saveOptions);
}
{'fraction_non_alphanumeric': 0.14766449020592667, 'fraction_numerical': 0.0030135610246107484, 'mean_word_length': 3.6325581395348836, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '1048739', 'n_tokens_mistral': 576, 'n_tokens_neox': 565, 'n_words': 110}