<commit_before>const $ = require('jquery');

function DisplayMessage(){
}

DisplayMessage.prototype.showWinMessage = function(){
  var div = $('#post-game');
  div.empty()
     .show()
     .append(`<h1>You Win!</h1>
              <p>Click to play the next level.</p>`
            );

  div.on('click', function(){
    div.hide();
  });
}

DisplayMessage.prototype.showHighScoreMessage = function(game, leaderboard){
  var div = $('#post-game');
  div.empty()
     .show()
     .append(`<h1>High Score!</h1>
              <p>Name:</p>
              <input class='input'></input>
              <button>Submit</button>`
            );

  div.on('click', 'button', function(){
    var input = $('.input').val();<commit_msg>Remove event listener in game win to avoid multiplication<commit_after>const $ = require('jquery');

function DisplayMessage(){
}

DisplayMessage.prototype.showWinMessage = function(){
  var div = $('#post-game');
  div.empty()
     .show()
     .append(`<h1>You Win!</h1>
              <p>Click to play the next level.</p>`
            );

  div.on('click', function(){
    div.hide();
  });
}

DisplayMessage.prototype.showHighScoreMessage = function(game, leaderboard){
  var div = $('#post-game');
  div.empty()
     .show()
     .append(`<h1>High Score!</h1>
              <p>Name:</p>
              <input class='input'></input>
              <button id="high-submit-button">Submit</button>`
            );
  div.unbind('click').on('click', 'button', function() {
    var input = $('.input').val();
{'fraction_non_alphanumeric': 0.19553805774278216, 'fraction_numerical': 0.005249343832020997, 'mean_word_length': 2.6223277909738716, 'pattern_counts': {'":': 0, '<': 27, '<?xml version=': 0, '>': 27, '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': '623223', 'n_tokens_mistral': 476, 'n_tokens_neox': 465, 'n_words': 92}