// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
//
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// compiled file.
//
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
// about supported directives.
//
//= require jquery
//= require jquery.turbolinks
//= require jquery_ujs
//= require jquery-ui/autocomplete
//= require autocomplete-rails
//= require bootstrap-sprockets
//= require bootstrap-switch
//= require sorttable
//= require turbolinks
//= require_tree .
Turbolinks.ProgressBar.enable();

$(document).on('ready page:load page:restore', function(event) {
    if (/player/.test(window.location.href)) {
        switches_and_select();
        sorttable.makeSortable(document.getElementById('player-records'));
    }
});

@@ -936,59 +936,8 @@
 ) %7B%0A
-    if (/player/.test(window.location.href)) %7B%0A    
     
@@ -959,20 +959,16 @@
 lect();%0A
-    
     sort
@@ -1034,14 +1034,7 @@
 ));%0A
-    %7D%0A
 %7D)
-;
 %0A

Revert "Only run switches_and_select and sorttable.makeSortable on /player/"