js/tinymce/plugins/spellchecker/plugin.js
function filter(callback) {
        var filteredMatches = [];

        each(function (match, i) {
          if (callback(match, i)) {
            filteredMatches.push(match);
          }
        });

        matches = filteredMatches;

        /*jshint validthis:true*/
        return this;
      }
function filter(callback) {
        var filteredMatches = [];

        each(function (match, i) {
          if (callback(match, i)) {
            filteredMatches.push(match);
          }
        });

        matches = filteredMatches;

        /*jshint validthis:true*/
        return this;
      }
function filter ( callback ) { var filteredMatches = [ ] ; each ( function ( match , i ) { if ( callback ( match , i ) ) { filteredMatches . push ( match ) ; } } ) ; matches = filteredMatches ; /*jshint validthis:true*/ return this ; }
Filters the matches. If the callback returns true it stays if not it gets removed.

@param {Function} callback Callback to execute for each match.
@return {DomTextMatcher} Current DomTextMatcher instance.
Filters the matches . If the callback returns true it stays if not it gets removed .