Standardizing on .test() and .exec() - moving away from using .match() for RegExp. Fixes jQuery bug #4113.

This commit is contained in:
John Resig 2009-07-19 13:21:51 +00:00
parent a3b8ac413f
commit 0d5c3a68a0
7 changed files with 20 additions and 20 deletions

View file

@ -132,7 +132,7 @@ jQuery.fn.extend({
if ( /toggle|show|hide/.test(val) )
e[ val == "toggle" ? hidden ? "show" : "hide" : val ]( prop );
else {
var parts = val.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),
var parts = /^([+-]=)?([\d+-.]+)(.*)$/.exec(val),
start = e.cur(true) || 0;
if ( parts ) {