Bug in .destroy() when deferrender is used
Bug in .destroy() when deferrender is used
RagingTroll
Posts: 34Questions: 3Answers: 0
(I'm using the last version of DT available on GitHub)
When calling .destroy(), this line is crashing
[code]$( rows ).removeClass( settings.asStripeClasses.join(' ') );[/code]
because when deferrender is on, some of the rows are null, so we first need to filter these out like this (or any other way you prefer)
[code]$( rows ).filter(function() {
return this != null;
}) .removeClass( settings.asStripeClasses.join(' ') );[/code]
When calling .destroy(), this line is crashing
[code]$( rows ).removeClass( settings.asStripeClasses.join(' ') );[/code]
because when deferrender is on, some of the rows are null, so we first need to filter these out like this (or any other way you prefer)
[code]$( rows ).filter(function() {
return this != null;
}) .removeClass( settings.asStripeClasses.join(' ') );[/code]
This discussion has been closed.
Replies
Allan