mirror of
https://github.com/DataTables/DataTables.git
synced 2026-04-25 03:00:08 -04:00
Fix: Selector couldn't be given as an API instance with indexes
- It is useful to be able to filter row indexes by a condition and then operate on the resulting array of indexes, but before the selector would only itterate over real arrays. So if you passed is an API instance with the result set being the indexes to delete, it wouldn't work! - Fix is to loop over anything which has a `length` property - Thread 20572
This commit is contained in:
@@ -1 +1 @@
|
||||
7af052b65bad5f70edd2aa928eab03ce43206081
|
||||
d9f416232bb33d53cc9a6f006416bf19c385ebe4
|
||||
|
||||
2
media/js/jquery.dataTables.js
vendored
2
media/js/jquery.dataTables.js
vendored
@@ -7290,7 +7290,7 @@
|
||||
out = [], res,
|
||||
a, i, ien, j, jen;
|
||||
|
||||
if ( ! $.isArray( selector ) ) {
|
||||
if ( ! selector || selector.length === undefined ) {
|
||||
selector = [ selector ];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user