Fixed the two semicolons: http://dev.jquery.com/changeset/6412

Adding the second argument to parseInt makes sense only for userinput,
here the first argument value always start with a non-zero.

Jörn

On Wed, Jun 10, 2009 at 1:15 PM, dwt<mhaec...@schwarz-online.org> wrote:
>
> Hi there,
>
> I just found some warnings in qunit from jslint, so I provide a patch
> here.
>
> -- snip --
> Index: testrunner.js
> ===================================================================
> --- testrunner.js       (Revision 301)
> +++ testrunner.js       (Revision 302)
> @@ -371,20 +371,22 @@
>        if ( !validTest(name) )
>                return;
>
>        synchronize(function() {
>                config.assertions = [];
>                config.expected = null;
>                try {
>                        if( !pollution )
>                                saveGlobal();
>                        lifecycle.setup();
>                } catch(e) {
>                        QUnit.ok( false, "Setup failed on " + name + ": " + 
> e.message );
>                }
> -       })
> +       });
>        synchronize(function() {
>                try {
>                        callback();
>                } catch(e) {
>                        if( typeof console != "undefined" && console.error &&
> console.warn ) {
>                                console.error("Test " + name + " died, 
> exception and test
> follows");
> @@ -399,11 +401,11 @@
>        synchronize(function() {
>                try {
>                        checkPollution();
>                        lifecycle.teardown();
>                } catch(e) {
>                        QUnit.ok( false, "Teardown failed on " + name + ": " +
> e.message );
>                }
> -       })
> +       });
>        synchronize(function() {
>                try {
>                        reset();
> @@ -571,7 +573,7 @@
>  * @result "data/test.php?foo=bar&10538358345554"
>  */
>  function url(value) {
> -       return value + (/\?/.test(value) ? "&" : "?") + new Date().getTime()
> + "" + parseInt(Math.random()*100000);
> +       return value + (/\?/.test(value) ? "&" : "?") + new Date().getTime()
> + "" + parseInt(Math.random()*100000, 10);
>  }
>
>  /**
> -- snap --
>
> Regards,
> Martin
>
> p.s.: Since I won't read the mailinglist, please also send replies to
> my address.
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.
To post to this group, send email to jquery-dev@googlegroups.com
To unsubscribe from this group, send email to 
jquery-dev+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to