<commit_before>onload = function() {
  var feedUrlNode = document.getElementById('feed-url');
  feedUrlNode.focus();

  document.getElementById('intent-form').onsubmit = function(event) {
    var feedUrl = feedUrlNode.value;

    var intent = new WebKitIntent(
        'http://webintents.org/view', 'application/atom+xml', feedUrl);

    window.navigator.webkitStartActivity(intent);

    event.preventDefault();
  };
}<commit_msg>Use an explicit intent when we want to invoke ourselves.<commit_after>onload = function() {
  var feedUrlNode = document.getElementById('feed-url');
  feedUrlNode.focus();

  document.getElementById('intent-form').onsubmit = function(event) {
    var feedUrl = feedUrlNode.value;

    var intent = new WebKitIntent({
      action: 'http://webintents.org/view',
      type: 'application/atom+xml',
      data: feedUrl,
      // Use an explicit intent so that we don't trigger the picker, and instead
      // we handle it directly.
      service: location.protocol + '//' + location.hostname + '/main.html'
    });

    window.navigator.webkitStartActivity(intent);

    event.preventDefault();
  };
}
{'fraction_non_alphanumeric': 0.134394341290893, 'fraction_numerical': 0.0, 'mean_word_length': 3.6584362139917697, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '2913185', 'n_tokens_mistral': 332, 'n_tokens_neox': 322, 'n_words': 73}