1
0
mirror of https://github.com/DataTables/DataTables.git synced 2025-02-18 16:54:14 +01:00

Fix: asStripClasses if given was being overruled by the default given for asStripeClasses - 8332

Fix: The extend function was only extending properties that existed on the original source object, not properties that only existed on the extender
This commit is contained in:
Allan Jardine 2012-02-02 10:04:51 +00:00
parent 92ce6487f2
commit de6482a15e
3 changed files with 6 additions and 6 deletions

View File

@ -4577,9 +4577,9 @@
*/
function _fnExtend( oOut, oExtender )
{
for ( var prop in oOut )
for ( var prop in oExtender )
{
if ( oOut.hasOwnProperty(prop) && oExtender[prop] !== undefined )
if ( oExtender.hasOwnProperty(prop) )
{
if ( typeof oInit[prop] === 'object' && $.isArray(oExtender[prop]) === false )
{
@ -6219,8 +6219,8 @@
_fnMap( oSettings.oScroll, oInit, "bScrollInfinite", "bInfinite" );
_fnMap( oSettings.oScroll, oInit, "iScrollLoadGap", "iLoadGap" );
_fnMap( oSettings.oScroll, oInit, "bScrollAutoCss", "bAutoCss" );
_fnMap( oSettings, oInit, "asStripClasses", "asStripeClasses" ); // legacy
_fnMap( oSettings, oInit, "asStripeClasses" );
_fnMap( oSettings, oInit, "asStripClasses", "asStripeClasses" ); // legacy
_fnMap( oSettings, oInit, "fnServerData" );
_fnMap( oSettings, oInit, "fnFormatNumber" );
_fnMap( oSettings, oInit, "sServerMethod" );

View File

@ -103,8 +103,8 @@ _fnMap( oSettings.oScroll, oInit, "bScrollCollapse", "bCollapse" );
_fnMap( oSettings.oScroll, oInit, "bScrollInfinite", "bInfinite" );
_fnMap( oSettings.oScroll, oInit, "iScrollLoadGap", "iLoadGap" );
_fnMap( oSettings.oScroll, oInit, "bScrollAutoCss", "bAutoCss" );
_fnMap( oSettings, oInit, "asStripClasses", "asStripeClasses" ); // legacy
_fnMap( oSettings, oInit, "asStripeClasses" );
_fnMap( oSettings, oInit, "asStripClasses", "asStripeClasses" ); // legacy
_fnMap( oSettings, oInit, "fnServerData" );
_fnMap( oSettings, oInit, "fnFormatNumber" );
_fnMap( oSettings, oInit, "sServerMethod" );

View File

@ -166,9 +166,9 @@ function _fnMap( oRet, oSrc, sName, sMappedName )
*/
function _fnExtend( oOut, oExtender )
{
for ( var prop in oOut )
for ( var prop in oExtender )
{
if ( oOut.hasOwnProperty(prop) && oExtender[prop] !== undefined )
if ( oExtender.hasOwnProperty(prop) )
{
if ( typeof oInit[prop] === 'object' && $.isArray(oExtender[prop]) === false )
{