Skip to content
Permalink
Browse files

jquery core: closes #3053. clean() wasn't parsing 0's. So html( 0 ) w…

…as failing failing.
  • Loading branch information
flesler committed Jun 17, 2008
1 parent 2f2602e commit 5e50079b1472d9fef27fdc3f59c0f2e494556dd9
Showing with 4 additions and 4 deletions.
  1. +4 −4 src/core.js
@@ -943,12 +943,12 @@ jQuery.extend({
context = context.ownerDocument || context[0] && context[0].ownerDocument || document;

jQuery.each(elems, function(i, elem){
if ( typeof elem == 'number' )
elem += '';

if ( !elem )
return;

if ( elem.constructor == Number )
elem += '';

// Convert html string into DOM nodes
if ( typeof elem == "string" ) {
// Fix "XHTML"-style tags in all browsers
@@ -1368,4 +1368,4 @@ jQuery.each([ "Height", "Width" ], function(i, name){
// Helper function used by the dimensions and offset modules
function num(elem, prop) {
return elem[0] && parseInt( jQuery.curCSS(elem[0], prop, true), 10 ) || 0;
}
}

0 comments on commit 5e50079

Please sign in to comment.
You can’t perform that action at this time.