Issue #1880798 by droplet: Fixed tableselect.js performances.

PR for http://drupal.org/node/1880798
I don't think $table exists here, so this would cause a JS error.