Skip to content
Permalink
Browse files

Added a fix for when trim receives a null value (bug #1395).

  • Loading branch information
jeresig committed Jul 20, 2007
1 parent 42f30dd commit a2482e5e87558edb2be67fd6e7369bb62168fde9
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/jquery/jquery.js
@@ -1607,7 +1607,7 @@ jQuery.extend({
* @cat JavaScript
*/
trim: function(t){
return t.replace(/^\s+|\s+$/g, "");
return (t||"").replace(/^\s+|\s+$/g, "");
},

makeArray: function( a ) {

0 comments on commit a2482e5

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