Changeset 22737
- Timestamp:
- 11/21/2012 08:09:28 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/js/media-models.js
r22706 r22737 326 326 327 327 _changeFilteredProp: function( prop, model, term ) { 328 // Bail if we're currently searching for the same term. 329 if ( this.props.get( prop ) === term ) 328 // If this is a query, updating the collection will be handled by 329 // `this._requery()`. 330 if ( this.props.get('query') ) 330 331 return; 331 332 … … 338 339 // from, then automatically generate a source from the existing 339 340 // models. 340 if ( ! this. props.get('source'))341 this. props.set( 'source', new Attachments( this.models ));342 343 this.reset( this. props.get('source').filter( this.validator) );341 if ( ! this._source ) 342 this._source = new Attachments( this.models ); 343 344 this.reset( this._source.filter( this.validator, this ) ); 344 345 }, 345 346
Note: See TracChangeset
for help on using the changeset viewer.