Bug in _fnReOrderIndex: Attempts to split() an array
Bug in _fnReOrderIndex: Attempts to split() an array

I am using 1.9.4 and server-side processing. If the server returns the columns in a different order than that specified in the table, _fnReOrderIndex() is called and throws an exception when it attempts to split sColumns (an array) into an array (line 341).
As a quick fix I changed that to the following -- though aColumns can be outright replaced with sColumns if it will always be an array.
[code]
var aColumns;
if ($.isArray(sColumns) ) {
aColumns = sColumns;
} else {
aColumns = sColumns.split(',');
}
[/code]
As a quick fix I changed that to the following -- though aColumns can be outright replaced with sColumns if it will always be an array.
[code]
var aColumns;
if ($.isArray(sColumns) ) {
aColumns = sColumns;
} else {
aColumns = sColumns.split(',');
}
[/code]
This discussion has been closed.
Replies
I'd suggest using mData if you can - its more flexible and will give a performance benefit as well since the arrays don't need to be reordered.
Allan