mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
MINOR Avoid applying jstree plugin multiple times when onmatch is called on CSS class changes, rather than DOM insertions
This commit is contained in:
parent
0c6bc2f7a1
commit
746e3ea05e
@ -13,6 +13,9 @@
|
||||
onmatch: function() {
|
||||
this._super();
|
||||
|
||||
// Don't reapply (expensive) tree behaviour if already present
|
||||
if(!$.isNaN(this.data('jstree_instance_id'))) return;
|
||||
|
||||
var hints = this.attr('data-hints');
|
||||
if(hints) this.setHints($.parseJSON(hints));
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user