mirror of
https://github.com/DataTables/DataTables.git
synced 2025-01-18 11:52:11 +01:00
Dev fix: Fix flatten, which was returning an array rather than an API
instance
This commit is contained in:
parent
dd36646723
commit
73d36854e3
@ -309,9 +309,11 @@ _Api.prototype = /** @lends DataTables.Api */{
|
||||
|
||||
flatten: function ()
|
||||
{
|
||||
return this.reduce( function ( a, b ) {
|
||||
var a = this.reduce( function ( a, b ) {
|
||||
return a.concat( b );
|
||||
} );
|
||||
|
||||
return new _Api( this.context, a );
|
||||
},
|
||||
|
||||
|
||||
@ -436,6 +438,7 @@ _Api.prototype = /** @lends DataTables.Api */{
|
||||
push: _arrayProto.push,
|
||||
|
||||
|
||||
// Does not return an API instance
|
||||
reduce: _arrayProto.reduce || function ( fn, init )
|
||||
{
|
||||
var
|
||||
|
Loading…
x
Reference in New Issue
Block a user